File tree Expand file tree Collapse file tree 1 file changed +46
-0
lines changed Expand file tree Collapse file tree 1 file changed +46
-0
lines changed Original file line number Diff line number Diff line change 1+ <?php
2+
3+ declare (strict_types=1 );
4+
5+ namespace Fig \Attributes ;
6+
7+ /**
8+ * One-Line summary of what the attribute does
9+ *
10+ * ## Target audience
11+ *
12+ * Implementors
13+ * : Who should handle this attribute? Example: "static analysis tools"
14+ * Users
15+ * : Who adds this attribute to their code? Example: "packages that want to
16+ * safeguard their functions via static analysis
17+ *
18+ * Long explanation of what the attribute does and why it is relevant.
19+ *
20+ * Use citations[^citation] or [Links](https://example.com) in your text to make
21+ * sure people understand the relevance and where you got your ideas from.
22+ *
23+ * If your Attribute has preconditions for usage you MUST use the keywords
24+ * described in [RFC 2119](https://datatracker.ietf.org/doc/html/rfc2119).
25+ * You SHOULD list them prominently.
26+ *
27+ * **Note:** DocBlock content MUST be Markdown formatted. Check out the
28+ * [Markdown-Guide](https://www.markdownguide.org/) for possible formatting
29+ *
30+ * Please also use code-snippets where appropriate
31+ *
32+ * ```php
33+ * <?php
34+ * echo 'Hello World';
35+ * ```
36+ *
37+ * You MUST describe parameters to your Attribute extensively! You SHOULD use
38+ * the well-known Annotations for that
39+ *
40+ * @param string $example_1 Does x and y
41+ * @param boolean $example_2
42+ *
43+ * [^citation] https://en.wikipedia.org/wiki/Citation
44+ */
45+ #[\Attribute(\Attribute::TARGET_CLASS )]
46+ final class Template {}
You can’t perform that action at this time.
0 commit comments