@nifrajs/ts-plugin
v3.1.0
Published
TypeScript language-service plugin for nifra - go-to-definition from a route-path string literal to the routes/ file that serves it.
Maintainers
Readme
@nifrajs/ts-plugin
A TypeScript language-service plugin for nifra. It adds go-to-definition on route-path string literals: put your cursor on "/orders" in navigate({ to: "/orders" }), <Link to="/orders">, or href="/orders", and jump straight to the routes/ file that serves it.
The routing rules are nifra's own - it discovers routes with @nifrajs/web and matches them with @nifrajs/core's pattern matcher - so a path resolves to exactly the file it would serve at runtime, dynamic segments included (/users/42 → routes/users/[id].tsx).
Install
npm install -D @nifrajs/ts-pluginEnable
Add it to your tsconfig.json:
{
"compilerOptions": {
"plugins": [{ "name": "@nifrajs/ts-plugin" }]
}
}In VS Code, run "TypeScript: Select TypeScript Version" from the Command Palette and choose "Use Workspace Version" so the editor loads the plugin from your project.
For agents
Start with LLM.md - this package's contract card (the exports it ships and how it wires in). llms-full.txt is the full machine-readable corpus for the whole framework.
License
MIT
