Skip to content
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

PR submission #1

Open
3 tasks
alecdwm opened this issue Jan 31, 2023 · 0 comments
Open
3 tasks

PR submission #1

alecdwm opened this issue Jan 31, 2023 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@alecdwm
Copy link
Member

alecdwm commented Jan 31, 2023

We've made the changes needed to get SVG support working in our own monorepo.
They're available on npm at @alectalisman/preconstruct-cli@2.3.0-e.

But maintenance of this fork will fall to us unless we can get something pushed upstream.

Preconstruct's design goals include completely abstracting away the rollup configuration, so we can expect its maintainers will reject a PR which attempts to simply expose that config to users.

I'm hoping we might be able to find a compromise between no support for svg imports and fully exposed rollup configuration.

My plan is to integrate svgr as a separate feature of preconstruct.
The feature will expose a limited number of configuration options as children on the preconstruct package.json config.
Limited because we want to be sure that future @svgr/rollup changes don't create breaking changes for preconstruct users unless absolutely necessary.

Todos

  • Convert svgr integration from a hardcoded fork into an optional, configurable feature
  • Add tests to check that the feature works as intended (and that preconstruct throws helpful errors when it's switched off)
  • Add docs for preconstruct users to know:
    • what the feature does
    • how to turn it on
    • what configuration options are available
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