Open ghost opened 8 years ago
In your index.html
file (I would recommend deleting the above configuration and instead putting your template html file at src/index.html
, unless you truly need something special), add this code:
Right before the closing </head>
tag:
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.97.6/css/materialize.min.css”>
Right before the closing </body>
:
<script src="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.97.6/js/materialize.min.js"></script>
That should prevent the /template
routing issues and CORS error.
Does that help?
I don't know webpack well, I followed this conversation and was able to create a template HTML for me. `webpack: {
}`
Now I'd like to add MaterializeCss framework in my HTML, but it fails.
I tried using CDN but I constantly get CORS error. I tried to load files from local directory
/template
but I get 404 not found, because it tries to read from localhost:3000/template/js/materialize.jsHow can I add a css link in header and js scripts in body?
Thanks.