{"_id":"@2forweb/create-symfony-fe-app","_rev":"3-b6edb70c2e0f2940a6af93e682b0319e","name":"@2forweb/create-symfony-fe-app","dist-tags":{"latest":"1.0.2"},"versions":{"1.0.0":{"name":"@2forweb/create-symfony-fe-app","version":"1.0.0","keywords":["controllers","frontend","react","stimulus","symfony","typescript","vite"],"author":{"name":"Matias Jose"},"license":"ISC","_id":"@2forweb/create-symfony-fe-app@1.0.0","maintainers":[{"name":"shadowc","email":"info@matiasjose.com"}],"bin":{"create-symfony-fe-app":"dist/index.js"},"dist":{"shasum":"c1fc5e0e6683decc7cb4a66ce5b1a7e8e7521743","tarball":"https://registry.npmjs.org/@2forweb/create-symfony-fe-app/-/create-symfony-fe-app-1.0.0.tgz","fileCount":36,"integrity":"sha512-VxF959OtN4ODPX7CDYiJcZx7fgA/hfKuBsHLuUa+0jUPNtiVmj7/KkTo87L3FDTOiVf5dwMNBltj175OWH6j1g==","signatures":[{"sig":"MEUCIQCaqBjpeYEvEw4WW29q81OvbcsX4VUPLp72XwuOPZbN/wIgNMQ/u4GDhLmKmYYATZiWAqP47+hi0FaFuC7hd+7vYic=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":81202},"main":"index.js","type":"commonjs","gitHead":"95cb6be6d70e67cc2f521a823cfcbc15ffb63648","scripts":{"fmt":"oxfmt --check src/**/*.ts","lint":"oxlint src/**/*.ts","test":"echo \"Error: no test specified\" && exit 1","build":"node ./node_modules/.bin/vite build","fmt:fix":"oxfmt src/**/*.ts","typecheck":"tsc --noEmit","build:watch":"node ./node_modules/.bin/vite build --watch"},"_npmUser":{"name":"shadowc","email":"info@matiasjose.com"},"_npmVersion":"11.11.0","description":"A tool to create a fancy vite based symfony front-end application where you can maintain your stimulus and react controllers in TypeScript on its own folder","directories":{},"_nodeVersion":"24.14.1","_hasShrinkwrap":false,"devDependencies":{"vite":"^8.0.1","oxfmt":"^0.42.0","oxlint":"^1.57.0","typescript":"^5.9.3","@types/node":"^25.5.0"},"_npmOperationalInternal":{"tmp":"tmp/create-symfony-fe-app_1.0.0_1775500648386_0.9877323835260741","host":"s3://npm-registry-packages-npm-production"}},"1.0.1":{"name":"@2forweb/create-symfony-fe-app","version":"1.0.1","keywords":["controllers","frontend","react","stimulus","symfony","typescript","vite"],"author":{"name":"Matias Jose"},"license":"ISC","_id":"@2forweb/create-symfony-fe-app@1.0.1","maintainers":[{"name":"shadowc","email":"info@matiasjose.com"}],"bin":{"create-symfony-fe-app":"dist/index.js"},"dist":{"shasum":"6666322a425a317e0c9973e04c09845586a95fb9","tarball":"https://registry.npmjs.org/@2forweb/create-symfony-fe-app/-/create-symfony-fe-app-1.0.1.tgz","fileCount":51,"integrity":"sha512-k5ov8gWPja+KlDnYAiSUbLX40aMkyPSAEocR09wCT54I3MYKObl82698ETD/77vzslNnOd3mckCsq1qc7/8pGw==","signatures":[{"sig":"MEUCIQChjiSchtBdaVODq5Y+7OItRIwSpEAUFih+t/IHejOkjwIgRLlt47EeXUlNkireeOH3ahHSq41fcYyH9vcg5ApWL48=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":116429},"main":"index.js","type":"commonjs","gitHead":"d24ea8fbd1a0cd2487b468bdbfd7be9c67159d76","scripts":{"fmt":"oxfmt --check src/**/*.ts","lint":"oxlint src/**/*.ts","test":"vitest run","build":"node ./node_modules/.bin/vite build","fmt:fix":"oxfmt src/**/*.ts","typecheck":"tsc --noEmit","build:watch":"node ./node_modules/.bin/vite build --watch"},"_npmUser":{"name":"shadowc","email":"info@matiasjose.com"},"_npmVersion":"11.11.0","description":"A tool to create a fancy vite based symfony front-end application where you can maintain your stimulus and react controllers in TypeScript on its own folder","directories":{},"_nodeVersion":"24.14.1","_hasShrinkwrap":false,"devDependencies":{"vite":"^8.0.1","oxfmt":"^0.42.0","oxlint":"^1.57.0","vitest":"^4.1.4","typescript":"^5.9.3","@types/node":"^25.5.0"},"_npmOperationalInternal":{"tmp":"tmp/create-symfony-fe-app_1.0.1_1776293843520_0.6417153963627722","host":"s3://npm-registry-packages-npm-production"}},"1.0.2":{"name":"@2forweb/create-symfony-fe-app","version":"1.0.2","description":"A tool to create a fancy vite based symfony front-end application where you can maintain your stimulus and react controllers in TypeScript on its own folder","keywords":["controllers","frontend","react","stimulus","symfony","typescript","vite"],"license":"ISC","author":{"name":"Matias Jose"},"bin":{"create-symfony-fe-app":"dist/index.js"},"type":"commonjs","main":"index.js","scripts":{"typecheck":"tsc --noEmit","build":"node ./node_modules/.bin/vite build","build:watch":"node ./node_modules/.bin/vite build --watch","lint":"oxlint src/**/*.ts","fmt":"oxfmt --check src/**/*.ts","fmt:fix":"oxfmt src/**/*.ts","test":"vitest run"},"devDependencies":{"@types/node":"^25.5.0","oxfmt":"^0.42.0","oxlint":"^1.57.0","typescript":"^5.9.3","vite":"^8.0.1","vitest":"^4.1.4"},"gitHead":"195d65576873e643c178814535852016e4a42f83","_id":"@2forweb/create-symfony-fe-app@1.0.2","_nodeVersion":"24.14.1","_npmVersion":"11.11.0","dist":{"integrity":"sha512-LEbXMA5H3X6/ErwxzSK/+jqYkjsf5LDe/EEX2UifqEK3k1UJb28BUtxhSUPxrRehDgrzaOY+GY/x8aHSlA0skg==","shasum":"a1ad71a2bde7a189f6a45851d0008b61402b729e","tarball":"https://registry.npmjs.org/@2forweb/create-symfony-fe-app/-/create-symfony-fe-app-1.0.2.tgz","fileCount":51,"unpackedSize":117468,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIFoO6pbl3jwbkDAywCHuQhdH1H2nnQhrB195esJASwCqAiAuRbR4x1CPAbVs7tG1zX2yQLL8Ick30sLoHqSnoLFS+A=="}]},"_npmUser":{"name":"shadowc","email":"info@matiasjose.com"},"directories":{},"maintainers":[{"name":"shadowc","email":"info@matiasjose.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/create-symfony-fe-app_1.0.2_1776294678090_0.7805524510483766"},"_hasShrinkwrap":false}},"time":{"created":"2026-04-06T18:37:28.290Z","modified":"2026-04-15T23:11:18.423Z","1.0.0":"2026-04-06T18:37:28.539Z","1.0.1":"2026-04-15T22:57:23.674Z","1.0.2":"2026-04-15T23:11:18.259Z"},"author":{"name":"Matias Jose"},"license":"ISC","keywords":["controllers","frontend","react","stimulus","symfony","typescript","vite"],"description":"A tool to create a fancy vite based symfony front-end application where you can maintain your stimulus and react controllers in TypeScript on its own folder","maintainers":[{"name":"shadowc","email":"info@matiasjose.com"}],"readme":"# create-symfony-fe-app\n\n[![Node Tests](https://github.com/2forWeb/create-symfony-fe-app/actions/workflows/node.js.yml/badge.svg)](https://github.com/2forWeb/create-symfony-fe-app/actions/workflows/node.js.yml)\n\n`create-symfony-fe-app` is a Command-line tool that adds a `TypeScript` based frontend scaffolding based on **Vite** to an existing **Symfony** project. This command will create a `client` folder with the following optional elements:\n\n- `TypeScript` `StimlusJS` controllers under `/client/controllers`\n- `TypeScript` `React` controllers under `/client/react`\n- `tailwindcss` using `symfonycasts/tailwind-bundle`\n- `oxlint`/`oxfmt` for linting\n\nSome folders under `assets` will be added to `.gitignore`, tieing it all together with build and typecheck commands based on `Vite` and `tsc`.\n\n## Build command\n\nYou will be able to go from `/client` to `/assets` with a build command based on `Vite` to transpile `TypeScript` into files usable by `asset-mapper` in `symfony`. This means that the transpilation proccess is simplistic, and no hashing will be used for file names, so that `asset-mapper` can later `build` these into real `bundle` files in the `public` folder.\n\n## Frontend elements\n\n### TypeScript Stimulus controllers\n\n`client/controllers` will contain your `TypeScript` `StimulusJS` controllers to be compiled into `assets/controllers`.\n\nSince the `/assets/controllers` folder will be gitignored, the original controllers living there, like `csrf_controller.js`, will be copied back from `/asstes` into `/client/original-controllers` where the build process will copy them back into the now gitignored `/assets/controllers` without modification. You can of course manage the contents of this `/client/original-controllers` folder, for example deleting `hello_controller.js` since it's not needed.\n\n### TypeScript React controllers\n\nUsing the `symfony/ux-react` package, you will be able to have typehinted `TypeScript` react components under `client/react` which will transpile into the now gitignored folder `/assets/react/controllres`.\n\n### Tailwindcss\n\nThis will install the package `symfonycasts/tailwind-bundle` and make your system ready for use with `TailwindCSS`. In this case, no folder will be created in `/client`, as `SASS` or `LESS` are not recommended for use with `tailwind`.\n\n### Oxlint Oxfmt\n\nThis option will install `oxlint` and `oxfmt` packages together with a simple setup to have a good `symfony` themed linting on the `TypeScript` files living under `/client`. You will also be able to type-check your client with `tsc` using `npm` commands (recommended for CI).\n\n### Symfony local\n\nThe tool will add **`symfony local`** watcher commands where applicable so that your files get built instantly on every change should you use the `symfony serve` command for local development.\n\n## Installation\n\nInstall the application by running:\n\n```bash\nnpm i --save-dev @2forweb/create-symfony-fe-app\n```\n\nor globally by running:\n\n```bash\nnpm i -g @2forweb/create-symfony-fe-app\n```\n\n## How to run\n\nThe application is meant to run from the root folder of your functioning `symfony` application. (best done with a fresh `symfony` install).\n\n```bash\nnpx create-symfony-fe-app\n```\n\n## Interactive mode\n\nRunning the command without parameters will start interactive mode where you will see a short welcome message and instructions.\n\nUse **↑** / **↓** to move, **Space** to toggle each stack option and **Enter** to confirm. You can hit **Esc** to quit without doing anything.\n\n> Picking no options will also quit without action.\n\nOnce you pick your options, the app wil ask you to confirm installing both needed `npm` and `composer` packages. Type `y` or `yes` to agree and the tasks will start. Any other response will abort the operation.\n\nIt then runs the install and file tasks and reports success or failure if anything wrong happens.\n\n## Non-interactive\n\nUse **`--no-interactive`** or **`-y`** to skip the menu and the npm/Composer confirmation prompts. Tasks will run immediately with the default selection of tasks.\n\nRunning:\n\n```bash\ncreate-symfony-fe-app --no-interactive\ncreate-symfony-fe-app -y\n```\n\nWill install `StimulusJS` controllers and `oxlint`/`oxfmt` setup.\n\nYou can change this by specifying in the command line which options you want to enable. This will switch to an \"options only\" mode where only the specified options will take place:\n\n### Choosing stacks from the CLI\n\n| Flag         | Enables                         |\n| ------------ | ------------------------------- |\n| `--stimulus` | TypeScript Stimulus controllers |\n| `--react`    | TypeScript React components     |\n| `--tailwind` | TailwindCSS                     |\n| `--oxlint`   | OxLint / OxFormat               |\n\nIf you pass **any** of these flags, **only** those stacks will be selected (everything else will be turned off).\n\nExamples:\n\n```bash\n# Defaults (Stimulus + OxLint), no prompts\ncreate-symfony-fe-app -y\n\n# Only Tailwind, no prompts\ncreate-symfony-fe-app -y --tailwind\n\n# Multiple stacks, no prompts\ncreate-symfony-fe-app --no-interactive --stimulus --react --tailwind --oxlint\n```\n","readmeFilename":"README.md"}