Skip to content

feat: export everything from entry points - #710

Merged
aarthificial merged 1 commit into
motion-canvas:mainfrom
aarthificial:entry-point
May 23, 2023
Merged

feat: export everything from entry points#710
aarthificial merged 1 commit into
motion-canvas:mainfrom
aarthificial:entry-point

Conversation

@aarthificial

@aarthificial aarthificial commented May 23, 2023

Copy link
Copy Markdown
Contributor

This PR introduces new ES bundles for both core and 2d. They contain the same things as the lib directory, except rolled up into one single file.

As of right now, they are not published to npm to prevent mistakenly mixing them with the contents of the lib directory.
In v4, the lib directories will be removed and replaced with these bundles.

To make it possible, all entities should now be imported directly from the package's entry point:

import {all, createRef} from '@motion-canvas/core';
import {makeScene2D, Circle} from '@motion-canvas/2d';

Importing from subdirectories will continue working until v4.

All entities should now be imported directly from the package's entry point:
```ts
import {all, createRef} from '@motion-canvas/core';
import {makeScene2D, Circle} from '@motion-canvas/2d';
```

Importing from subdirectories will continue working until v4.
@aarthificial
aarthificial merged commit 3c885d9 into motion-canvas:main May 23, 2023
@aarthificial
aarthificial deleted the entry-point branch May 23, 2023 08:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant