Skip to content

Commit

Permalink
Build r149
Browse files Browse the repository at this point in the history
  • Loading branch information
paulmasson committed Feb 25, 2023
1 parent ace5ba7 commit 4025d40
Show file tree
Hide file tree
Showing 8 changed files with 685 additions and 23 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
node_modules
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License

Copyright © 2010-2022 three.js authors
Copyright © 2010-2023 three.js authors

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
22 changes: 5 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,27 +7,15 @@ Vanilla [Three.js](https://github.com/mrdoob/three.js) including basic controls.

The steps to create this build from a [stable](https://github.com/mrdoob/three.js/issues/20591) tagged version are

* Perform a shallow clone of the desired version with
* Edit the version number of `three` in `package.json` to indicate the desired version. These numbers are of the form `0.nnn.n`, where the last digit reflects possible modifications after the first release. Available versions can be displayed with `npm show three versions`.

`git clone --depth=1 --branch r<n> --single-branch https://github.com/mrdoob/three.js.git`
* Configure the library with `npm install`.

* Add a single line to `src/Three.js` just after all other exports
* Build the library with `npm run build`.

`export { OrbitControls } from '../examples/jsm/controls/OrbitControls.js';`
The minified file will be located in the `build` directory.

* Revert the import `from 'three';` in `OrbitControls.js` to

`from '../../../build/three.module.js';`

* Move into the library directory with `cd three.js`

* Configure the library with `npm install`

* Build the library with `npm run build`

The minified file will be located in the `build` directory and has been copied to the same directory here.

If you need additional features, then simply add the appropriate `export` lines to `src/Three.js` and build the library yourself.
If you need additional features, then simply add the appropriate `export` lines to `Three.js` and build the library yourself.

Live examples using this build via [MathCell](https://github.com/paulmasson/mathcell):

Expand Down
3 changes: 3 additions & 0 deletions Three.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@

export * from 'three';
export { OrbitControls } from 'three/examples/jsm/controls/OrbitControls.js';
10 changes: 5 additions & 5 deletions build/three.min.js

Large diffs are not rendered by default.

Loading

0 comments on commit 4025d40

Please sign in to comment.