Setup a pure HTML/CSS components project with Webpack
up vote
0
down vote
favorite
I'm new to configuring webpack. I know it's used a lot for application frameworks like React, Angular, etc; but I don't need those. I'm asked to setup a project where we'll create components in pure HTML/CSS(Sass)/JS that will later on be put together for templates, (purely for design purposes). Basically similar to how React does its components without React itself.
How do I setup a project similar to the structure below with webpack and the plugins that go with it?
Many Thanks
Example structure:
-rootfolder:
-dist/
-src/
-components/
-progress-bar:
-progress-bar.html
-progress-bar.scss
-progress-bar.js
-accordion/
-accordion.html
-accordion.scss
-accordion.js
-alert/
-alert.html
-alert.scss
-alert.js
-templates/
-home.html
-user-profile.html
-user-dashboard.html
javascript html css webpack webpack-4
add a comment |
up vote
0
down vote
favorite
I'm new to configuring webpack. I know it's used a lot for application frameworks like React, Angular, etc; but I don't need those. I'm asked to setup a project where we'll create components in pure HTML/CSS(Sass)/JS that will later on be put together for templates, (purely for design purposes). Basically similar to how React does its components without React itself.
How do I setup a project similar to the structure below with webpack and the plugins that go with it?
Many Thanks
Example structure:
-rootfolder:
-dist/
-src/
-components/
-progress-bar:
-progress-bar.html
-progress-bar.scss
-progress-bar.js
-accordion/
-accordion.html
-accordion.scss
-accordion.js
-alert/
-alert.html
-alert.scss
-alert.js
-templates/
-home.html
-user-profile.html
-user-dashboard.html
javascript html css webpack webpack-4
add a comment |
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I'm new to configuring webpack. I know it's used a lot for application frameworks like React, Angular, etc; but I don't need those. I'm asked to setup a project where we'll create components in pure HTML/CSS(Sass)/JS that will later on be put together for templates, (purely for design purposes). Basically similar to how React does its components without React itself.
How do I setup a project similar to the structure below with webpack and the plugins that go with it?
Many Thanks
Example structure:
-rootfolder:
-dist/
-src/
-components/
-progress-bar:
-progress-bar.html
-progress-bar.scss
-progress-bar.js
-accordion/
-accordion.html
-accordion.scss
-accordion.js
-alert/
-alert.html
-alert.scss
-alert.js
-templates/
-home.html
-user-profile.html
-user-dashboard.html
javascript html css webpack webpack-4
I'm new to configuring webpack. I know it's used a lot for application frameworks like React, Angular, etc; but I don't need those. I'm asked to setup a project where we'll create components in pure HTML/CSS(Sass)/JS that will later on be put together for templates, (purely for design purposes). Basically similar to how React does its components without React itself.
How do I setup a project similar to the structure below with webpack and the plugins that go with it?
Many Thanks
Example structure:
-rootfolder:
-dist/
-src/
-components/
-progress-bar:
-progress-bar.html
-progress-bar.scss
-progress-bar.js
-accordion/
-accordion.html
-accordion.scss
-accordion.js
-alert/
-alert.html
-alert.scss
-alert.js
-templates/
-home.html
-user-profile.html
-user-dashboard.html
javascript html css webpack webpack-4
javascript html css webpack webpack-4
edited Nov 8 at 3:54
asked Nov 8 at 3:26
Shaoz
5,788245491
5,788245491
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
up vote
1
down vote
accepted
The way to setup a Webpack project for just HTML/SASS/JS is pretty much similar to setting up a React project. If you Google webpack 4 zero config you'll find some very good articles that give you some step-by-step instructions.
You will need the following plugins with Webpack 4:
1. html-webpack-plugin
2. mini-css-extract-plugin
Thanks Jose for responding. I'll have a look at the plugins.
– Shaoz
Nov 13 at 3:18
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
1
down vote
accepted
The way to setup a Webpack project for just HTML/SASS/JS is pretty much similar to setting up a React project. If you Google webpack 4 zero config you'll find some very good articles that give you some step-by-step instructions.
You will need the following plugins with Webpack 4:
1. html-webpack-plugin
2. mini-css-extract-plugin
Thanks Jose for responding. I'll have a look at the plugins.
– Shaoz
Nov 13 at 3:18
add a comment |
up vote
1
down vote
accepted
The way to setup a Webpack project for just HTML/SASS/JS is pretty much similar to setting up a React project. If you Google webpack 4 zero config you'll find some very good articles that give you some step-by-step instructions.
You will need the following plugins with Webpack 4:
1. html-webpack-plugin
2. mini-css-extract-plugin
Thanks Jose for responding. I'll have a look at the plugins.
– Shaoz
Nov 13 at 3:18
add a comment |
up vote
1
down vote
accepted
up vote
1
down vote
accepted
The way to setup a Webpack project for just HTML/SASS/JS is pretty much similar to setting up a React project. If you Google webpack 4 zero config you'll find some very good articles that give you some step-by-step instructions.
You will need the following plugins with Webpack 4:
1. html-webpack-plugin
2. mini-css-extract-plugin
The way to setup a Webpack project for just HTML/SASS/JS is pretty much similar to setting up a React project. If you Google webpack 4 zero config you'll find some very good articles that give you some step-by-step instructions.
You will need the following plugins with Webpack 4:
1. html-webpack-plugin
2. mini-css-extract-plugin
answered Nov 8 at 13:06
Jose Guerra
543
543
Thanks Jose for responding. I'll have a look at the plugins.
– Shaoz
Nov 13 at 3:18
add a comment |
Thanks Jose for responding. I'll have a look at the plugins.
– Shaoz
Nov 13 at 3:18
Thanks Jose for responding. I'll have a look at the plugins.
– Shaoz
Nov 13 at 3:18
Thanks Jose for responding. I'll have a look at the plugins.
– Shaoz
Nov 13 at 3:18
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53201130%2fsetup-a-pure-html-css-components-project-with-webpack%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown