Skip to content

Use SCSS instead of inline Styles #1

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

Open
maxigimenez opened this issue Apr 5, 2020 · 0 comments
Open

Use SCSS instead of inline Styles #1

maxigimenez opened this issue Apr 5, 2020 · 0 comments
Labels
enhancement New feature or request

Comments

@maxigimenez
Copy link
Owner

At the moment we need to use inline CSS due to the shadow-dom and the encapsulation:

getStyles(): HTMLStyleElement {
    const stylesheet = document.createElement('style');
    stylesheet.innerHTML = `
      .my-component {
        border: 1px solid red;
      }
    `;
    return stylesheet;
  }

It would be nice to remove this implementation in favor of write SASS or CSS and import the generated styles into the web-component.

@maxigimenez maxigimenez added the enhancement New feature or request label Apr 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant