contributte/webpack-skeleton

Webpack 4 project skeleton based on Nette Framework (@nette) and Contributte (@contributte) libraries by @f3l1x.

Installs: 30

Dependents: 0

Suggesters: 0

Security: 0

Stars: 40

Watchers: 6

Forks: 7

Open Issues: 1

Language:JavaScript

Type:project


README

68747470733a2f2f62616467656e2e6e65742f6769746875622f636865636b732f636f6e74726962757474652f7765627061636b2d736b656c65746f6e2f6d6173746572 68747470733a2f2f62616467656e2e6e65742f636f766572616c6c732f632f6769746875622f636f6e74726962757474652f7765627061636b2d736b656c65746f6e 68747470733a2f2f62616467656e2e6e65742f7061636b61676973742f646d2f636f6e74726962757474652f7765627061636b2d736b656c65746f6e 68747470733a2f2f62616467656e2e6e65742f7061636b61676973742f762f636f6e74726962757474652f7765627061636b2d736b656c65746f6e

68747470733a2f2f62616467656e2e6e65742f7061636b61676973742f7068702f636f6e74726962757474652f7765627061636b2d736b656c65746f6e 68747470733a2f2f62616467656e2e6e65742f6769746875622f6c6963656e73652f636f6e74726962757474652f7765627061636b2d736b656c65746f6e 68747470733a2f2f62616467656e2e6e65742f62616467652f737570706f72742f6769747465722f6379616e 68747470733a2f2f62616467656e2e6e65742f62616467652f737570706f72742f666f72756d2f79656c6c6f77 68747470733a2f2f62616467656e2e6e65742f62616467652f73706f6e736f722f646f6e6174696f6e732f463936383534

Website 🚀 contributte.org | Contact 👨🏻‍💻 f3l1x.io | Twitter 🐦 @contributte

68747470733a2f2f6170692e6d6963726f6c696e6b2e696f3f75726c3d68747470732533412532462532466578616d706c65732e636f6e74726962757474652e6f72672532467765627061636b2d736b656c65746f6e253246266f7665726c61792e62726f777365723d6c696768742673637265656e73686f743d74727565266d6574613d66616c736526656d6265643d73637265656e73686f742e75726c

Goal

Main goal is to provide webpack starter-kit project for Nette developers.

Demo

https://examples.contributte.org/webpack-skeleton/

Installation

You will need PHP 7.4+ and Composer.

Create project using composer.

composer create-project -s dev contributte/webpack-skeleton acme

Install Composer dependencies: composer install

Install NPM dependencies: npm install

Now you have application installed. It's time to run it.

Startup

Backend

The easiest way is to use php built-in web server.

php -S 0.0.0.0:8000 -t www

Then visit http://localhost:8000 in your browser.

Frontend

If you want compile assets, call npm run start.

If you need watcher, call npm run watch, it will watch your codebase and rebuild assets.

If you want build for production, call npm run build.

If you want start webpack development server with HRM, call npm run dev, open http://localhost:8080 in your browser.

Features

  • 👍 Nette 3.0
  • 👍 Webpack configuration
    • 🎉 extracting JS to single bundle
    • 🎉 extracting CSS to single file
    • 🎉 more bundles (front/admin/vendor)
  • 👍 Snippets
    • 🎉 few snippets
  • 👍 Nette Form
    • 🎉 AJAX submitting
    • 🎉 form builder
      • empty value on control (@ in email)
      • validation rules (filled + email)
      • simple filter (transform email to lowercase)
      • onValidate / onSubmit / onSuccess
    • 🎉 manual rendering
      • success snippet / error snippet
      • required class on form-group
      • description on control

Screenshots

webpack.png

phpserver.png

web.png