canirequire

canirequireCommonJS › @emotion/core

Is @emotion/core ESM-only? Can you require() it?

Last verified Sep 9, 2026 against @emotion/core@11.0.0. JSON

CommonJS CommonJS — require() works on every Node.js version

@emotion/core ships CommonJS only. require("@emotion/core") works everywhere. import "@emotion/core" also works because Node.js and Bun can import CommonJS from ES modules, but only the default export is guaranteed; named imports depend on Node's static analysis of the module.

Latest
11.0.0 (Nov 12, 2020)
Module format
CommonJS
Last CommonJS version
11.0.0
TypeScript types
Bundled
Node engines
not declared
License
MIT

Does @emotion/core@11.0.0 actually load? Runtime test results

Installed and executed on Sep 9, 2026 with require("@emotion/core") from a CommonJS file and import "@emotion/core" from an ES module.

Runtimerequire("@emotion/core")import "@emotion/core"
Node.js 18✗ failsError: The `@emotion/core` package has been renamed to `@emotion/react`. Please import it like this `import { jsx } from '@emotion/react'`.✗ failsError: The `@emotion/core` package has been renamed to `@emotion/react`. Please import it like this `import { jsx } from '@emotion/react'`.
Node.js 20✗ failsError: The `@emotion/core` package has been renamed to `@emotion/react`. Please import it like this `import { jsx } from '@emotion/react'`.✗ failsError: The `@emotion/core` package has been renamed to `@emotion/react`. Please import it like this `import { jsx } from '@emotion/react'`.
Node.js 22✗ failsError: The `@emotion/core` package has been renamed to `@emotion/react`. Please import it like this `import { jsx } from '@emotion/react'`.✗ failsError: The `@emotion/core` package has been renamed to `@emotion/react`. Please import it like this `import { jsx } from '@emotion/react'`.
Node.js 24✗ failsError: The `@emotion/core` package has been renamed to `@emotion/react`. Please import it like this `import { jsx } from '@emotion/react'`.✗ failsError: The `@emotion/core` package has been renamed to `@emotion/react`. Please import it like this `import { jsx } from '@emotion/react'`.
Node.js 26✗ failsError: The `@emotion/core` package has been renamed to `@emotion/react`. Please import it like this `import { jsx } from '@emotion/react'`.✗ failsError: The `@emotion/core` package has been renamed to `@emotion/react`. Please import it like this `import { jsx } from '@emotion/react'`.
Bun 1.4✗ failserror: The `@emotion/core` package has been renamed to `@emotion/react`. Please import it like this `import { jsx } from '@emotion/react'`.✗ failserror: The `@emotion/core` package has been renamed to `@emotion/react`. Please import it like this `import { jsx } from '@emotion/react'`.

A failing require() on a CommonJS package usually means the package needs a browser/DOM global, a peer dependency, or a native binary that is not available in a bare Node.js process.

How to import @emotion/core

ES modules (import)

import core from "@emotion/core";

Named imports from a CommonJS package only work when Node.js can statically detect them. If a named import fails, use the default import and destructure.

CommonJS (require)

const core = require("@emotion/core");

Module format by version

Derived from the type, main and exports fields of every stable release on npm (57 versions; the newest 57 shown).

VersionsFormatFirst published
0.0.4 – 11.0.0CommonJSFeb 9, 2018

Frequently asked

Is @emotion/core ESM-only?

@emotion/core@11.0.0 is a CommonJS package. @emotion/core ships CommonJS only. require("@emotion/core") works everywhere. import "@emotion/core" also works because Node.js and Bun can import CommonJS from ES modules, but only the default export is guaranteed; named imports depend on Node's static analysis of the module.

Can I import @emotion/core with ES module syntax?

Yes. import core from "@emotion/core" works in Node.js and Bun because they support importing CommonJS modules. Named imports work only when Node.js can statically detect the exports.

Does @emotion/core work in Bun?

Importing @emotion/core failed in Bun 1.4 on Sep 9, 2026: error: The `@emotion/core` package has been renamed to `@emotion/react`. Please import it like this `import { jsx } from '@emotion/react'`.

Does @emotion/core ship TypeScript types?

Yes. @emotion/core bundles its own type declarations; no @types package is needed.

Links

Other commonjs packages

Similar popularity