Template Webpack
This template provides a solid foundation for modern JavaScript development, streamlining your workflow with a powerful combination of tools. It leverages Webpack for efficient bundling and optimization of your assets, ensuring top-notch performance. Integrated within this setup are ESLint for maintaining code quality and catching potential errors, Prettier for enforcing a consistent and clean code style, and Babel for transpiling your JavaScript code to ensure compatibility across different browsers. This pre-configured environment saves you valuable time and effort, allowing you to focus on building your application's core logic rather than wrestling with complex configurations. It's an ideal starting point for projects of any size, offering a robust and scalable architecture from the get-go.
To install Template Webpack, follow these steps:
- Clone the repository:
git clone https://github.com/Big-Plato/template-webpack.git
- Navigate to the project directory:
cd template webpack
- Install dependencies:
npm install
- Build the project:
npm run build
- Start the project:
npm run dev
To use template-webpack
, follow these steps:
-
Open the project in your favorite code editor.
-
Modify the source code to fit your needs.
-
Build the project:
npm run build
-
Start the project:
npm run dev
-
Configure eslint to fit your project
npm init @eslint/config@latest
-
To run eslint you can do
npm run config /path/to/js
( change/path/to/js
to the file or folder you want to lint) -
When everything is right the dependencies in
package.json
will be like this:"devDependencies": { "@babel/core": "^7.26.9", "@babel/preset-env": "^7.26.9", "@eslint/js": "^9.20.0", "babel-loader": "^9.2.1", "css-loader": "^7.1.2", "eslint": "^8.57.1", "globals": "^16.0.0", "html-loader": "^5.1.0", "html-webpack-plugin": "^5.6.3", "prettier": "3.5.1", "style-loader": "^4.0.0", "webpack": "^5.98.0", "webpack-cli": "^6.0.1", "webpack-dev-server": "^5.2.0" },
-
in
/src/
there are templates for mainhtml
,css
andjavascript
files. -
Use the project as desired.
If you'd like to contribute to 'Template Webpack', here are some guidelines:
- Fork the repository.
- Create a new branch for your changes.
- Make your changes.
- Write tests to cover your changes.
- Run the tests to ensure they pass.
- Commit your changes.
- Push your changes to your forked repository.
- Submit a pull request.
Template Webpack is released under the MIT License. See the LICENSE file for details.
Template Webpack was created by Luis OctΓ‘vio.
If you have any questions or comments about this template, please contact Luis OctΓ‘vio.