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

Patch#2: DefineModule, StateModule #259

Merged
merged 47 commits into from
Jun 30, 2017
Merged

Patch#2: DefineModule, StateModule #259

merged 47 commits into from
Jun 30, 2017

Conversation

sasha240100
Copy link
Member

@sasha240100 sasha240100 commented Jun 24, 2017

This PR is not yet complete and please do not merge it yet.

Patch includes:

  • DefineModule - replaces modules as CameraModule
    • Make deprecations.
  • Removed camera: {} and light: {}.
  • StateModule
  • ElementModule
    • now: new ElementModule(domObject)
  • ModuleManager
    • Implement manager.require
    • document manager.require
  • whitestorm.js -> whs.js
  • Production sourceMaps
  • Circle & Cone added

README.md Outdated
@@ -77,7 +77,7 @@ You can find lots of examples at [showcases](https://whs-dev.surge.sh/examples/)
const app = new WHS.App([
new WHS.ElementModule(), // attach to DOM
new WHS.SceneModule(), // creates THREE.Scene instance
new WHS.CameraModule(), // creates PerspectiveCamera instance
new WHS.DefineModule('camera', new WHS.PerspectiveCamera()), // creates PerspectiveCamera instance
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we have to be careful with updating readme, (well doc too if we publish early) as this module is not available with beta releases yet.

@@ -3,14 +3,14 @@ import * as UTILS from '../../globals';
const ad = UTILS.appDefaults;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this example was broken btw. not sure perhaps we should remove it, the area light from three.js is an odd one.

package.json Outdated
@@ -31,6 +31,7 @@
"license": "MIT",
"homepage": "https://github.com/WhitestormJS/whitestorm.js#readme",
"dependencies": {
"@types/node": "^7.0.32",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what is this for?

@@ -16,8 +16,8 @@ test('SceneModule', () => {
modules.scene = new WHS.SceneModule();
});

test('CameraModule', () => {
modules.camera = new WHS.CameraModule();
test('DefineModule', () => {
Copy link
Collaborator

@hirako2000 hirako2000 Jun 24, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

when we modify classes, I think we should try to add proper tests/assertions.
Maybe just check that data was populated with the passed in param (PerspectiveCamera), with the passed name?

@sasha240100 sasha240100 changed the title [WIP] Patch#2 Patch#2: DefineModule, StateModule Jun 27, 2017
@sasha240100 sasha240100 merged commit a40e5d8 into beta Jun 30, 2017
@sasha240100 sasha240100 deleted the patch#2 branch June 30, 2017 19: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