Skip to content

Commit f3efe86

Browse files
committed
Add @notundefined to the decorators file in the editor tooling
1 parent 90f59ab commit f3efe86

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

analysis/src/CompletionDecorators.ml

+13
Original file line numberDiff line numberDiff line change
@@ -297,4 +297,17 @@ let toplevel =
297297

298298
[Read more and see examples in the documentation](https://rescript-lang.org/docs/manual/latest/jsx#file-level-configuration).|};
299299
] );
300+
( "notUndefined",
301+
None,
302+
[
303+
{|The `@notUndefined` decorator marks an abstract type as one that can never be `undefined` in JavaScript. This allows the compiler to generate more efficient code when the type is used inside an `option`.
304+
305+
Example usage:
306+
```rescript
307+
@notUndefined
308+
type t
309+
```
310+
311+
[Read more and see examples in the documentation](https://rescript-lang.org/syntax-lookup#notundefined-decorator).|};
312+
] );
300313
]

0 commit comments

Comments
 (0)