Skip to content

[FEAT] add support for css modules #80

@abhijithvijayan

Description

@abhijithvijayan

adjusting webpack config like

		{
            loader: 'css-loader', // Takes the CSS files and returns the CSS with imports and url(...) for Webpack
            options: {
              sourceMap: true,
              modules: {
                localIdentName: isDevelopment
                  ? '[path][name]__[local]'
                  : '[hash:base64]',
              },
              importLoaders: 1,
            },
          },

will add support for css modules so that

import styles from './styles.scss';

export const Login: React.FC = () => {
  return (
    <section className={styles.login}>
      <h2>extension</h2>
    </section>
  );
};

will work fine

Screenshot 2021-11-29 at 11 19 00

Metadata

Metadata

Assignees

No one assigned

    Labels

    effort: lowaround a day or less💡 Proposed WorkThis is work that _might_ be worth doing, but that hasn't been started yet.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions