question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Icon component doesn't work with preact-boilerplate

See original GitHub issue

Hey,

I’ve been trying out preact-material-components along with preact-boilerplate but things aren’t going so smoothly, I get this error when trying to use certain components (Icon being one of the many, they all give the same error)

webpack: Compiling...
Hash: 246d66e2749be1b08c22
Version: webpack 2.4.1
Time: 225ms
chunk    {0} bundle.js, 0.b603481d36874a65094c.hot-update.js (main) 481 kB [entry]
   [53] ./src/components/material/index.js 2.98 kB {0} [built]
  [123] ./~/css-loader?{"sourceMap":true,"importLoaders":1}!./~/postcss-loader?{}!./~/less-loader/dist?{"sourceMap":true}!./~/preact-material-components/
Icon/style.css 406 bytes {0} [built] [failed] [1 error]
     + 123 hidden modules

ERROR in ./~/css-loader?{"sourceMap":true,"importLoaders":1}!./~/postcss-loader?{}!./~/less-loader/dist?{"sourceMap":true}!./~/preact-material-components
/Icon/style.css
Module build failed:

      .mdc-icon-toggle--primary::before {
        background-color: color(var(--mdc-theme-primary, #3f51b5) a(14%)); } }
                        ^
Error evaluating function `color`: keyword.toLowerCase is not a function
      in /Users/mika/code/git/fswfototest/preact-boilerplate/node_modules/preact-material-components/Icon/style.css (line 425, column 26)
 @ ./~/preact-material-components/Icon/style.css 4:14-156 13:2-17:4 14:20-162
 @ ./src/components/material/index.js
 @ ./src/components/app.js
 @ ./src/index.js
 @ multi (webpack)-dev-server/client?http://localhost:8080 webpack/hot/dev-server ./index.js
Child html-webpack-plugin for "index.html":
    chunk    {0} index.html 543 kB [entry]
         + 4 hidden modules
webpack: Failed to compile.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:13 (13 by maintainers)

github_iconTop GitHub Comments

1reaction
mikaturkcommented, May 2, 2017

update: cloned your new repository since I didn’t change much and want maximum compatibility 😄

0reactions
prateekbhcommented, May 2, 2017

fyi… i just started it, will make it better soon.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Preact boilerplate. Based on create-react-app. - GitHub
This project was bootstrapped with Create React App.But for preact . Below you will find some information on how to perform common tasks....
Read more >
mxstbr/react-boilerplate - Gitter
In the quickstart theres this instruction: Edit the file at ./app/containers/HomePage/index.js so that the text of the <Button> component reads "Features!!!"...
Read more >
Using react-icons package with react-boilerplate
When I install react-icons and trying to import. import FaBeer from 'react-icons/fa/beer'; I get an error
Read more >
preact - npm
Preact exports a generic Component class, which can be extended to build encapsulated, self-updating pieces of a User Interface. Components ...
Read more >
Preact Authentication Tutorial - Auth0
Working with Forms in Preact is really no different from ReactJS except for non-existent support for static props. Classical components and ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found