You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Aug 26, 2021. It is now read-only.
Bug Report
What happened
React ES modules have .css require statements in them which causes several issues and is an anti-pattern.
For example
@gov.au/button
-> node_modules/@gov.au/buttons/lib/js/react.es5.js:6Line 6
require('../css/styles.css');
is not good for the following reasons listed here https://nextjs.org/docs/messages/css-npm:One issue is your packages by default are not supported by standard a Next.js install.
What I expected to happen
It would be great if we could import css separately, perhaps directly from pancake?
import '../../../../pancake/css/pancake.min.css'
Perhaps we don't need pancake for React components. Build tools like webpack are already quite optimised to shake out unneeded code.
The text was updated successfully, but these errors were encountered: