Skip to content

/pure build throws in browsers not supporting async-await #486

Closed
@eps1lon

Description

@eps1lon

More of a problem with kcd-scripts but I'm filing it here since the use case is more obvious. Feel free to transfer the issue.

  • react-testing-library version: 9.1.4
  • react version: N/A
  • node version: N/A
  • npm (or yarn) version: N/A

Relevant code or config:

import '@testing-library/react/pure'

What you did:

Used @testing-library/react in IE11

What happened:

Threw with unexpected identifier (due to async-await)

Reproduction:

mui/material-ui@1e54d49

failing build: https://circleci.com/gh/mui-org/material-ui/113431

Problem description:

kcd-scripts build will use babel but ignore any browserslists assuming the target is node: 8. Only rollup and webpack bundles will load browserslist

Suggested solution:

Add a browserslist targetting ie 11, node 8 and the last 3 versions of the evergreen browsers as well as:

No special case for babel targets. It should always use .browserslistrc since that supports a node entry as well. I think it didn't use to support a node version since I occasionally encounter a repository using browserslist but throwing with a node entry.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions