Colocate script, template, and styles in a single .rsfc file. TypeScript-first with CSS Modules — zero extra config needed.
Script, template, and styles live together in one .rsfc file. No scattered imports — everything your component needs in one place.
Scoped styles via <style module>. The styles object is auto-injected — zero class name collisions, ever.
Hot module replacement out of the box. Style-only changes update without re-rendering the component tree.
Three blocks. One file. Inspired by Vue SFCs, built for React.
Bootstrap your environment with the Vite plugin and React adapter.
npm install -D @g-casau/rsfc-vite-plugin @vitejs/plugin-reactEnable .rsfc support in your Vite configuration file.
import rsfc from '@g-casau/rsfc-vite-plugin'
// plugins: [rsfc(), react()]Add rsfc.d.ts to your project root for full TypeScript support.
Download the .vsix and install it in VS Code via Extensions → Install from VSIX for a full-featured RSFC development experience — syntax highlighting, IntelliSense, live diagnostics, and more.
Embedded grammars per block — TSX in templates, TypeScript in scripts, SCSS or CSS in styles, Markdown in docs.
Parse errors are surfaced inline as you type, directly from the RSFC compiler — no build step needed.
Full type checking via a tsserver plugin. Props, imports, and component exports all resolve correctly.
Type <script, <template or <style and press Tab to scaffold any block instantly with proper closing tags.
All RSFC blocks appear in the Explorer outline panel. Fold them individually and navigate at a glance.
Hover over any block to see its kind, language, and declared attributes in a Markdown tooltip.