-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rename some directories #2
Comments
Would be cool to see how this works in practice – I get how components and partials are different in the SCSS (component = buttons or form and partials = masthead or footer), but how does this breakdown in Statix? Would anything in components essentially be a styleguide only .hbs file? |
Other thing I just thought is it’s probably important to keep convention in terms of assemble terms. Bearing that in mind, I definitely think we should change Like I said above, if the |
I use components throughout my views and I also use them in the styleguide, they are massively helpful for me when creating a new site. I have to say that I don't really agree to keeping the FYI, here are my current Assemble settings: /**
* Assemble
* http://assemble.io/
* Static site generator used by Statix
* Find out more at https://github.com/tmwagency/statix
*/
assemble: {
options: {
data: '<%= config.statix.dir%>/src/**/*.{json,yml}',
assets: '<%= config.statix.dir%>/dist/assets/dist',
helpers: [
'helper-moment',
'handlebars-helper-eachitems',
'<%= config.statix.dir%>/src/helpers/helper-*.js',
'handlebars-helper-aggregate'
],
partials: [
'<%= config.statix.dir%>/src/templates/partials/**/*.hbs',
'<%= config.statix.dir%>/src/templates/styleguide/**/*.hbs',
'<%= config.statix.dir%>/src/templates/components/**/*.hbs'
],
flatten: false,
layout: 'default.hbs',
layoutdir: '<%= config.statix.dir%>/src/templates/layouts',
aggregate: {
cwd: '<%= config.statix.dir%>/src/templates/'
}
},
default: {
files: [{
cwd: './<%= config.statix.dir%>/src/templates/views/',
dest: '<%= site.destination %>',
expand: true,
src: ['**/*.{hbs,md}']
}]
}
} BTW, aggregate is a handlebars helper that I use to output a directory of |
Will be looking at bringing this (and the whole repo) more inline with Kickoff following latest updates. Will be doing this in next couple of weeks, so will add the updated folder structure to these changes – will update this issue as I get onto this. |
Nice one! 👍 |
Ok, so I’ve moved I’m inclined to keep the rest of the structure the same, as I want to keep the Devs can then add more folders if they feel the need to personalise the structure on their projects. For instance, at JE we have our components directory inside the Referencing the point that adding a components directory aligns with the SCSS folder – I guess it would, but I think it adds confusion over whether pieces of markup then go in the components directory or the partials directory. I’d rather keep this obvious unless people want to change it themselves (which is pretty simple to do). In an Assemble sense, components are just partial files that make up assemble pages. Does that make sense? 🙈 |
On my current project, that uses Statix, I have just renamed a few directories that I think might be of use to Statix as well, so...
New
These changes more closely match the directory structure of the
scss
folder and will hopefully ensure people use them in a similar way. Alsotemplates/components
is used quite successfully in my styleguide-driven development to for Handlebars partial files. What do you think? Happy to submit a PR if neededThe text was updated successfully, but these errors were encountered: