Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/k9i-0/k9i_macro_sample
https://github.com/k9i-0/k9i_macro_sample
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/k9i-0/k9i_macro_sample
- Owner: K9i-0
- Created: 2024-05-19T00:49:50.000Z (7 months ago)
- Default Branch: main
- Last Pushed: 2024-05-19T03:43:14.000Z (7 months ago)
- Last Synced: 2024-05-20T03:25:56.934Z (7 months ago)
- Language: Dart
- Size: 6.84 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
Awesome Lists containing this project
README
## 概要
シンプルなmacroのサンプルです。クラスに@Helloとアノテーションをつけると
```dart
@Hello()
class Sample {}
```こういうオーグメントが作られてhelloメソッドが利用可能になります
```dart
augment class Sample {
void hello() => print("Hello, World!");
}
```## 解説記事
https://zenn.dev/yumemi_inc/articles/6d526d0546b9f7