Closed NullVoxPopuli closed 2 years ago
For cross-referencing: https://github.com/josemarluedke/docfy/issues/111
Docfy generates routes at build time and instructs users to make their router include addDocfyRoutes:
addDocfyRoutes
I had tried to configured splitAtRoutes here: https://github.com/NullVoxPopuli/ember-cheat-sheet/blob/main/ember-cli-build.js#L23
splitAtRoutes: ['docs', 'docs.templates'],
which is the "name" of the routes. Confirmable here: https://cheatsheet.glimmer.nullvoxpopuli.com/docs (with the ember-inspector open)
Is my configuration correct? did I miss something in the splitAtRoutes docs?
splitAtRoutes
Could this be related to: https://github.com/embroider-build/embroider/issues/972 (I did try ember s with that environment variable, and it made no difference)
ember s
here is what running with splitAtRoutes uncomment looks like:
You need to switch to @embroider/router here:
@embroider/router
https://github.com/NullVoxPopuli/ember-cheat-sheet/blob/f44bd9451621998156d8ab1ea0362bef577bbe1d/app/router.ts#L1
ah ok -- only 2 subtle mentions of this:
https://github.com/embroider-build/embroider/search?l=Markdown&q=router
I must have missed it! Thanks!
For cross-referencing: https://github.com/josemarluedke/docfy/issues/111
Docfy generates routes at build time and instructs users to make their router include
addDocfyRoutes
:example router.js
```js import EmberRouter from '@ember/routing/router'; import { addDocfyRoutes } from '@docfy/ember'; import config from 'ember-cheat-sheet/config/environment'; export default class Router extends EmberRouter { location = config.locationType; rootURL = config.rootURL; } Router.map(function () { addDocfyRoutes(this); }); ```I had tried to configured splitAtRoutes here: https://github.com/NullVoxPopuli/ember-cheat-sheet/blob/main/ember-cli-build.js#L23
which is the "name" of the routes. Confirmable here: https://cheatsheet.glimmer.nullvoxpopuli.com/docs (with the ember-inspector open)![image](https://user-images.githubusercontent.com/199018/134012613-fde15c4e-aff6-4730-b14c-a2cf5d872665.png)
Is my configuration correct? did I miss something in the
splitAtRoutes
docs?Could this be related to: https://github.com/embroider-build/embroider/issues/972 (I did try
ember s
with that environment variable, and it made no difference)here is what running with splitAtRoutes uncomment looks like:![image](https://user-images.githubusercontent.com/199018/134013507-260927dc-7d76-4e61-8986-5db730222a74.png)