Giter Club home page Giter Club logo

Comments (3)

janivo avatar janivo commented on May 19, 2024 1
  1. Yes, it currently uses @import because it's outdated. So we would have to wait for stencil to upgrade it. I just kinda liked the solution because it's out of the box.
  2. You are right, that it's more transparent. We should do it this way.

from elements.

janivo avatar janivo commented on May 19, 2024

The variables.scss in src/components/styles is a global stylesheet that is loaded before all others. Would it not be sufficient to import the mdc-customize.scss there? This way we would not have to import it into every file.

If I understand correctly, we could use the injectGlobalPaths of the stencil-sass plugin.

We will have to wait until ionic-team/stencil-sass#38 is resolved or downgrade our stencil version to 1.x.x.

from elements.

pfecht avatar pfecht commented on May 19, 2024

I'm not quite sure if this is the proper solution.

  1. The global inject script looks like it uses @import, but we have to use @use statements to provide custom variables (see above).

  2. In my opinion it is more transparent to import our "mdc-customization" module before each "mdc import". It's different from importing variables since it resolves the mdc modules with our custom properties instead of defining variables. Furthermore, components that do not use mdc at all should not import the mdc customization file just for the sake of simplicity.

from elements.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.