sulu / ExampleNewsBundle

Sulu news example bundle
5 stars 3 forks source link

02: Bootstrap Bundle JavaScript #2

Open wachterjohannes opened 8 years ago

wachterjohannes commented 8 years ago

This part of the tutorial bootstraps the Bundle JavaScript extension and start a simple component with the route 'example/news'.

Link to the Blog-Post: http://blog.sulu.io/how-to-develop-a-bundle-in-the-sulu-admin-2

gusdecool commented 8 years ago

@wachterjohannes Looks like the tutorial is intended for symfony dev environment and most our reader new to sulu and without his knowledge using prod environment

So related with your tutorial, at the step we add file // file: Resources/public/js/main.js, for prod env it will give us error because the js looking for file at root/bundles/examplejs/dist/main/js, new guy will not get why sulu looking for dist folder that not exist and will be great if you explain how we can generate the dist folder.

wachterjohannes commented 8 years ago

@gusdecool in the last part of the tutorial there is a explanation how to build the dist files. http://blog.sulu.io/how-to-develop-a-bundle-in-the-sulu-admin-5

wachterjohannes commented 8 years ago

when you are runing symfony in develop you will see that the js/main.js file is loaded.