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

Line2: Convert Line2 example scripts to ES6 Classes #21495

Closed
wants to merge 3 commits into from

Conversation

gkjohnson
Copy link
Collaborator

Related issue: #19986

Description

Converts the examples/js/line/ files to use ES6 classes. Once the js files are removed (or built from the jsm files) the iife function definitions can be removed. Tested by running the following examples:

https://raw.githack.com/gkjohnson/three.js/line2-class/examples/webgl_lines_fat.html

https://raw.githack.com/gkjohnson/three.js/line2-class/examples/webgl_lines_fat_wireframe.html

And locally modifying the first to ensure raycasting returned hits only when hovering on the line

cc @WestLangley @DefinitelyMaybe

@Mugen87
Copy link
Collaborator

Mugen87 commented Mar 22, 2021

AFAIK, we do not convert code to ES6 classes in examples/js. When #20527 is solved, this is a different matter since a conversion script is available (ideally with optional ES5 conversion).

@gkjohnson
Copy link
Collaborator Author

Makes sense -- thanks!

@gkjohnson gkjohnson closed this Mar 23, 2021
@gkjohnson gkjohnson deleted the line2-class branch April 5, 2021 22:48
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.

2 participants