1.0.4 • Published 1 month ago

@toyokumo/fos-router v1.0.4

Weekly downloads
-
License
MIT
Repository
github
Last release
1 month ago

@toyokumo/fos-router

This is a npm package based on the js router of FOSJsRoutingBundle. The purpose is to be able to install the js router of FOSJsRoutingBundle without PHP dependency.

Usage

  1. Generate routes files

Generate routes files in JSON format using the FOSJsRoutingBundle command.

bin/console fos:js-routing:dump --format json --target generated/routes.js
  1. Install
npm i @toyokumo/fos-router
pnpm add @toyokumo/fos-router
yarn add @toyokumo/fos-router
  1. Import
import routes from './generated/routes.json';
import Router from '@toyokumo/fos-router';

Router.setRoutingData(routes);

See the FOSJsRoutingBundle documentation for details on how to use the bundle after import.

1.0.4

1 month ago

1.0.3

10 months ago

1.0.2

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago