Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Optional features #2068

Open
Razican opened this issue May 10, 2022 · 0 comments
Open

Optional features #2068

Razican opened this issue May 10, 2022 · 0 comments
Labels
API enhancement New feature or request
Milestone

Comments

@Razican
Copy link
Member

Razican commented May 10, 2022

Currently, the engine is provided as-is, with almost no room for customizing its features. Nevertheless, we have some situations (such as the optional #2067 feature, or the eval() function, or even not fully published features where it would be nice if the user of the engine could decide if they are available or not.

This can be provided by creating a feature for each of the features in the spec. Then, by default, we would include everything that is part of the spec and it's mandatory (still allowing our users to not use default features and pick each of them individually). Parts of the spec that are still only proposals (even if they are in test262) should not be included by default, but should be included when testing.

Furthermore, some users might not want all built-ins in the engine, to provide a smaller surface for their users, so we should provide an API where the global object is empty, and users can decide the list of globals that get added.

This would require extensive testing, so we would need to probably do a cargo check with each feature individually and --no-default-features.

@Razican Razican added enhancement New feature or request API labels May 10, 2022
@Razican Razican added this to the v0.16.0 milestone May 10, 2022
@Razican Razican modified the milestones: v0.16.0, v0.17.0 Sep 19, 2022
@Razican Razican modified the milestones: v0.17.0, v0.18.0 Jul 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
API enhancement New feature or request
Projects
Status: To do
Development

No branches or pull requests

1 participant