Skip to content

Imports in programmatic MDX pages require reboot of the web server #15881

@motleydev

Description

@motleydev

Description

If I try to import content to a programmatically processed mdx page, I must first reboot the server otherwise I get undefined.

Steps to reproduce

See this repo: https://github.com/motleydev/mdx-import-bug

Expected result

Imports should be immediately available.

Actual result

Imports are undefined until rebooting the server.

Environment

  System:
    OS: macOS 10.14.5
    CPU: (8) x64 Intel(R) Core(TM) i7-7700HQ CPU @ 2.80GHz
    Shell: 3.2.57 - /bin/bash
  Binaries:
    Node: 10.1.0 - ~/.nvm/versions/node/v10.1.0/bin/node
    Yarn: 1.6.0 - ~/.nvm/versions/node/v10.1.0/bin/yarn
    npm: 6.0.1 - ~/.nvm/versions/node/v10.1.0/bin/npm
  Languages:
    Python: 2.7.10 - /usr/bin/python
  Browsers:
    Chrome: 75.0.3770.142
    Firefox: 65.0
    Safari: 12.1.1
  npmPackages:
    gatsby: ^2.0.6 => 2.13.23 
    gatsby-image: ^2.0.6 => 2.2.6 
    gatsby-plugin-google-analytics: ^2.0.6 => 2.1.4 
    gatsby-plugin-layout: ^1.0.13 => 1.1.2 
    gatsby-plugin-manifest: ^2.0.2 => 2.2.3 
    gatsby-plugin-mdx: ^1.0.13 => 1.0.13 
    gatsby-plugin-netlify: ^2.0.16 => 2.1.3 
    gatsby-plugin-postcss: ^2.0.0 => 2.1.2 
    gatsby-plugin-prefetch-google-fonts: ^1.4.2 => 1.4.2 
    gatsby-plugin-react-helmet: ^3.0.0 => 3.1.2 
    gatsby-plugin-sharp: ^2.0.17 => 2.2.7 
    gatsby-plugin-sitemap: ^2.0.1 => 2.2.3 
    gatsby-plugin-styled-components: ^3.0.2 => 3.1.2 
    gatsby-plugin-typography: ^2.2.0 => 2.3.2 
    gatsby-plugin-webpack-bundle-analyzer: ^1.0.4 => 1.0.5 
    gatsby-remark-autolink-headers: ^2.0.16 => 2.1.3 
    gatsby-remark-check-links: ^1.1.5 => 1.1.5 
    gatsby-remark-code-repls: ^2.0.7 => 2.2.0 
    gatsby-remark-copy-linked-files: ^2.0.13 => 2.1.3 
    gatsby-remark-custom-blocks: ^2.0.6 => 2.1.2 
    gatsby-remark-embed-snippet: ^3.2.4 => 3.2.4 
    gatsby-remark-graphviz: ^1.1.2 => 1.1.2 
    gatsby-remark-images: ^2.0.3 => 2.0.6 
    gatsby-remark-prettier: ^1.0.0 => 1.0.0 
    gatsby-remark-prismjs: ^3.1.4 => 3.3.3 
    gatsby-remark-sectionize: ^1.0.0 => 1.0.0 
    gatsby-remark-video: ^1.2.1 => 1.2.1 
    gatsby-source-filesystem: ^2.0.1 => 2.1.5 
    gatsby-source-graphql: ^2.0.3 => 2.1.2 
    gatsby-transformer-remark: ^2.3.2 => 2.6.6 
    gatsby-transformer-sharp: ^2.1.2 => 2.2.3 
    gatsby-transformer-yaml: ^2.1.1 => 2.2.3 
  npmGlobalPackages:
    gatsby-cli: 2.6.2

Metadata

Metadata

Assignees

No one assigned

    Labels

    stale?Issue that may be closed soon due to the original author not responding any more.type: bugAn issue or pull request relating to a bug in Gatsby

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions