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

Fix support for baseUrl rewriting import.meta.url #2021

Merged
merged 2 commits into from
Apr 23, 2022

Commits on Apr 23, 2022

  1. Add support for baseUrl rewriting import.meta.url

    MDX can compile *and* run code, at the same time (called
    “evaluation”).
    To evaluate imports and exports in that code, it has to know *from
    where* to do that, which is a location on the users computer that is
    not the folder that contains `@mdx-js/mdx` in `node_modules`.
    That’s what the `baseUrl` option is used for.
    
    Previously though, the URL given as `baseUrl` was not used to replace
    `import.meta.url` in MDX code.
    As they are equivalent, this commit introduces that behavior.
    wooorm committed Apr 23, 2022
    Configuration menu
    Copy the full SHA
    d24a339 View commit details
    Browse the repository at this point in the history
  2. use dep

    wooorm committed Apr 23, 2022
    Configuration menu
    Copy the full SHA
    9506240 View commit details
    Browse the repository at this point in the history