feat: add typed WRN declarations

This commit is contained in:
2026-07-19 18:44:27 +05:30
parent 0d3ec79ee4
commit 94ae40d8bd
81 changed files with 942 additions and 241 deletions
+23
View File
@@ -4,6 +4,29 @@ Complete VS Code language support for [WRNexus](https://wrnexusjs.dev) `.wrn` fi
WRNexus is an SSR-first, Bun-powered full-stack framework with reactive components, layouts, colocated APIs, browser functions, lifecycle hooks, state watchers, client-side navigation, and reusable UI components.
Typed declarations work across props, state, and functions:
```wrn
component UserCard {
types {
interface User { id: string; name: string }
}
props {
user: User
compact: boolean = false
}
state selected: boolean = false
functions {
function select(user: User): void {
selected = true
}
}
view { <article>{user.name}</article> }
}
```
The extension shows declared prop types and reports missing required props and incompatible values. Typed prop and state expressions passed into nested components retain their declared type.
## Installation
Search for **WRNexus Language Support** in the VS Code Extensions view or run: