We recommend the following tooling:
- React Apps: Create React Apps or Parcel
- Static Sites: Eleventy or Awesome Static Web Site Generators
Using this generator will give you a solid base for your project in a matter of minutes. No matter if it’s a static website or a single page application.
Baumeister is here to help you to build your things by providing:
- a file structure with focus on maintainability and upgradability
- a build setup based on webpack and npm scripts with the following »features«
- generate static sites with ease using handlebars templates (optional)
- transpile, bundle and minify your code (ES6 as well as Sass)
- visualize size of bundled files with an interactive zoomable treemap
- remove
console
output anddebugger
statements in production files - add vendor prefixes
- lint JavaScript, Sass and HTML
- optimize images (lossless)
- start a local server
- delete unused CSS (optional)
- check for known vulnerabilities in dependencies
- release new versions
- run unit tests and create coverage reports
- and more.
Please check the epic README of »Baumeister« to get detailed information about what it’s all about.
There are tons of options for now 😱
… but don’t be afraid – most of them are optional and you probably won’t see them all because some are dependent on others. Plus the ones that probably don’t change from one project to another are stored for your convenience.
Option | Description |
---|---|
projectName |
Used in the generated README and package.json |
projectDescription |
Used in the generated README and package.json |
theme |
Name of your Bootstrap theme. Used to name a file and a folder within the Sass directory |
projectType |
Adds static site generator abilities (using Handlebars and Frontmatters), if you choose to build a static website. Sets up React with all the bells and whistles, if you choose to build a single page app. |
boilerplateAmount |
Option to choose the amount of boilerplate code (HTML, Sass and JS examples) |
license |
Option to define the license type. Defaults to MIT |
initialVersion |
Option to define the initial version number used in generated package.json. Defaults to 0.0.0 |
authorName |
Option to define the author for use in the generated package.json and JavaScript files |
authorMail |
Option to define the author for use in the generated package.json and JavaScript files |
authorUrl |
Option to define the author for use in the generated package.json |
projectHomepage , projectRepositoryType , projectRepository |
Option to define homepage and repository for use in the generated package.json |
issueTracker |
Option to define the URL to your issue tracker for use in the generated package.json |
banner |
Optionally adds a comment banner containing author name, version and build date to your production files (CSS and JS) |
addDistToVersionControl |
Option to decide whether to add the dist directory to version control or include it in .gitignore |
Frequent users, who are tired of being asked the same questions over again might like to use a config file called .yo-rc.json
described here.
For those already using Yeoman.
npm install -g generator-baumeister
yo baumeister
- Node.js (>=6.0.0)
- Globally installed Yeoman CLI
See detailed installation instructions over here if you are new to this.
Trick question. It's not a thing. It's this guy:
Basically, he wears a top hat, lives in your computer, and waits for you to tell him what kind of application you wish to create.
Not every new computer comes with a Yeoman pre-installed. He lives in the npm package repository. You only have to ask for him once, then he packs up and moves onto your hard drive. Make sure you clean up, he likes new and shiny things.
npm install -g yo
Yeoman travels light. He didn't pack any generators when he moved in. You can think of a generator like a plug-in. You get to choose what type of application you wish to create, such as a Backbone application or even a Chrome extension.
To install generator-baumeister from npm, run:
npm install -g generator-baumeister
Finally, initiate the generator:
yo baumeister
Do not remember prompt answers for next run of the generator
Default: false
yo baumeister --skip-cache
Do not automatically install dependencies
Default: false
yo baumeister --skip-install
Read and apply options from .yo-rc.json and skip prompting
Default: false
yo baumeister --yo-rc
You could place a .yo-rc.json
in the directory you are going to run the generator or in any parent directory up to your user directory (~/.yo-rc.json
)
This file should contain the options which are otherwise prompted by Yeoman. See the follwoing example .yo-rc.json
:
{
"generator-baumeister": {
"projectName": "My project",
"projectDescription": "My projects description",
"banners": false,
"projectType": "staticSite",
"theme": "my-theme",
"boilerplateAmount": "minimum",
"license": "MIT",
"authorName": "Michael Kühnel",
"authorUrl": "http://www.micromata.de",
"authorMail": "m.kuehnel@micromata.de",
"projectHomepage": "https://github.com/micromata/baumeister",
"projectRepositoryType": "git",
"projectRepository": "git@github.com:micromata/baumeister.git",
"issueTracker": "https://github.com/micromata/baumeister/issues",
"initialVersion": "1.0.0",
"addDistToVersionControl": false
}
}
See the Features of this generator.
Yeoman has a heart of gold. He's a person with feelings and opinions, but he's very easy to work with. If you think he's too opinionated, he can be easily convinced.
If you'd like to get to know Yeoman better, check out the complete Getting Started Guide.
Anyone and everyone is welcome to contribute. Please take a moment to review our Code of Conduct as well as our guidelines for contributing.
Please be aware of the licenses of the components we use in this project. Everything else that has been developed by the contributions to this project is under MIT License.