Comparing version 0.0.3 to 0.0.4
@@ -12,2 +12,3 @@ 'use strict'; | ||
var OrbitControls$1 = require('three/examples/jsm/controls/OrbitControls'); | ||
var DRACOLoader = require('three/examples/jsm/loaders/DRACOLoader'); | ||
@@ -41,2 +42,15 @@ reactThreeFiber.extend({ | ||
function draco(url) { | ||
if (url === void 0) { | ||
url = '/draco-gltf/'; | ||
} | ||
return function (loader) { | ||
var dracoLoader = new DRACOLoader.DRACOLoader(); | ||
dracoLoader.setDecoderPath(url); | ||
loader.setDRACOLoader(dracoLoader); | ||
}; | ||
} | ||
exports.OrbitControls = OrbitControls; | ||
exports.draco = draco; |
export * from './OrbitControls'; | ||
export * from './draco'; |
@@ -5,2 +5,3 @@ import _extends from '@babel/runtime/helpers/esm/extends'; | ||
import { OrbitControls as OrbitControls$1 } from 'three/examples/jsm/controls/OrbitControls'; | ||
import { DRACOLoader } from 'three/examples/jsm/loaders/DRACOLoader'; | ||
@@ -27,2 +28,10 @@ extend({ | ||
export { OrbitControls }; | ||
function draco(url = '/draco-gltf/') { | ||
return loader => { | ||
const dracoLoader = new DRACOLoader(); | ||
dracoLoader.setDecoderPath(url); | ||
loader.setDRACOLoader(dracoLoader); | ||
}; | ||
} | ||
export { OrbitControls, draco }; |
{ | ||
"name": "drei", | ||
"version": "0.0.3", | ||
"version": "0.0.4", | ||
"description": "useful add-ons for react-three-fiber", | ||
@@ -13,3 +13,3 @@ "main": "dist/index.cjs.js", | ||
"eslint": "eslint src/**/*.{js,ts,jsx,tsx}", | ||
"test": "jest", | ||
"test": "echo no tests yet", | ||
"typecheck": "tsc --noEmit --emitDeclarationOnly false --strict --jsx react", | ||
@@ -74,2 +74,3 @@ "typegen": "tsc && mv dist/src/* dist && rm -rf dist/src || true" | ||
"husky": "^4.2.5", | ||
"jest": "^25.4.0", | ||
"prettier": "^2.0.5", | ||
@@ -76,0 +77,0 @@ "pretty-quick": "^2.0.1", |
export * from './OrbitControls' | ||
export * from './draco' |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No tests
QualityPackage does not have any tests. This is a strong signal of a poorly maintained or low quality package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No README
QualityPackage does not have a README. This may indicate a failed publish or a low quality package.
Found 1 instance in 1 package
12013
14
261
0
13
38
2