Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

6.4.1 – src/assets/js/custom.js not included anymore like in 6.3.1? #10353

Closed
Moonbase59 opened this issue Jul 5, 2017 · 8 comments
Closed

Comments

@Moonbase59
Copy link

Moonbase59 commented Jul 5, 2017

The docs still say that all custom javascript files in src/assets/js/ automatically get included into app.js (6.3.1 did) but it seems not to? Anything changed due to webpack?

[F6.4.1/SASS on Ubuntu]

@kball
Copy link
Contributor

kball commented Jul 6, 2017

Hi @Moonbase59 - can you clarify, are you talking about in the ZURB stack? If so, the answer is yes it has shifted b/c it's moved to using true module dependency, and we need to update the docs. Can you highlight the ones in particular you're seeing the outdated info on? Thanks!

@Moonbase59
Copy link
Author

@kball http://foundation.zurb.com/sites/docs/starter-projects.html#javascript-compilation

Any easy way to do this correctly in 6.4.1, a link maybe?

@kball
Copy link
Contributor

kball commented Jul 6, 2017

@Moonbase59 essentially you'll want to simply import/require the files you want to include. I believe webpack allows you to do either node style require/exports (http://openmymind.net/2012/2/3/Node-Require-and-Exports/) or ES6 modules: http://exploringjs.com/es6/ch_modules.html

Will hopefully have time to update docs soon, but if you get things working well and want to submit a PR to update those, that would be AWESOME :)

@kball
Copy link
Contributor

kball commented Jul 19, 2017

Going to close this based on the initial docs improvement, but we'll be continuing to work on those docs as we go.

@kball kball closed this as completed Jul 19, 2017
@udf2457
Copy link

udf2457 commented Jan 29, 2018

@kball

A little nudge to see if you're getting any nearer improving those docs ? I stumbled across this problem today trying to work with the "new" FontAwesome 5 (https://fontawesome.com/get-started/svg-with-js).

Putting fontawesome-all.js into src/assets/js/ doesn't get compiled, I also tried src/assets/js/lib/ So getting the modern FA5 SVG w/JS is proving to be tedious.

@scottshuffler
Copy link

Same issue as @udf2457

@ncoden ncoden reopened this Feb 9, 2018
@ncoden ncoden self-assigned this Feb 9, 2018
ncoden added a commit to ncoden/foundation-sites that referenced this issue Feb 9, 2018
Changes:
* Add infos about webpack
* Add infos about Babel
* Update recommended import process
* Change list of useful resources

Closes foundation#10353
@ncoden ncoden added the PR open label Feb 9, 2018
@ncoden
Copy link
Contributor

ncoden commented Feb 9, 2018

@scottshuffler @udf2457 @Moonbase59 I updated the docs. See #10925.

Does it solves your problem ? Is the docs clear enough now ?

ncoden added a commit that referenced this issue Feb 10, 2018
…cript-doc-10353

docs: update ZURB template JavaScript docs #10353
@scottshuffler
Copy link

@ncoden LGTM

@ncoden ncoden closed this as completed Feb 12, 2018
ncoden added a commit to ncoden/foundation-sites that referenced this issue Jun 16, 2018
…te-javascript-doc-10353 for v6.5.0

8d92c80 docs: update ZURB template JavaScript docs foundation#10353
9c2f818 docs: fix typo in starter project docs

Signed-off-by: Nicolas Coden <nicolas@ncoden.fr>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants