Skip to content
This repository has been archived by the owner on Oct 5, 2020. It is now read-only.

As a slush-generator user, I'd like to have an easy and automated way of adding brand new html page to my project #487

Open
sashamitrovich opened this issue Mar 20, 2017 · 5 comments

Comments

@sashamitrovich
Copy link

Hint: I'd like to have a command-line option which allows me to generate a new html page, wire it wherever it needs to be wired and add a link to it from the main page. It should also include some static content.

Right now, doing this involves editing several files, creating folder(s) and new files and whatnot. It's too complicated for an average Joe, prone to errors and not documented.

@grtjn
Copy link
Contributor

grtjn commented Mar 20, 2017

Would be nice, but we'd have to reorganize a few things to make this at all possible, most importantly the ui app and folder structure. We would also need to extend the slush generator to allow maintenance on existing projects, rather than just generate new ones..

@grtjn
Copy link
Contributor

grtjn commented Aug 29, 2017

I had been thinking about taking the states in route.config.js apart, and adding them to xxx.module.js or maybe a xxx.route.js within the folder of each page individually. These files would also append to an some global appModuleDependencies variable that is used as parameter to the actual app module.

If organized that way, adding new pages would mostly be dropping in a new dir with some files that get hooked automatically that way. Header and nav bar should respond automatically too, but if made that way, we can easily add a gulp task to add a new page..

@patrickmcelwee
Copy link
Contributor

This seems promising. Would this also mean that reusable components could define a routes module that could just be imported and thereby available to the host application?

@grtjn
Copy link
Contributor

grtjn commented Aug 29, 2017

In theory yes, I think. Sounds appealing, right? The idea of pretty much only needing to bower install analytics-dashboard to have it show up in the menu, for instance..

@patrickmcelwee
Copy link
Contributor

Yes, that would be very appealing. In general, the easier we can make plugins, the better, I think.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants