Migrate to import * as React from 'react' and remove commonjs interop import #21697
Labels
help wanted
Issue with a clear description that the community can help with.
type: documentation
An issue or pull request for improving or updating Gatsby's documentation
type: maintenance
An issue or pull request describing a change that isn't a bug, feature or documentation change
Description
Reactjs has merged facebook/react#18102 and are moving into es module exports so the correct way of importing react will be
import * as React from 'react'
, they will keep the default exports to keep everything working as expecting.We should update our documentation and internal code to move to the new import statement.
Expected result
All react imports should be
import * as React from 'react'
Actual result
All react imports should be
import React from 'react'
More info:
The text was updated successfully, but these errors were encountered: