Skip to content

Commit 1fed1f7

Browse files
committed
node update
1 parent f95e93e commit 1fed1f7

File tree

3 files changed

+33
-28
lines changed

3 files changed

+33
-28
lines changed

README.md

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,16 @@
22
<img width="321" height="321" src="./imgs/logo-lowpoly.png">
33
</p>
44

5-
# Polyslice
6-
7-
An [FDM](https://en.wikipedia.org/wiki/Fused_filament_fabrication) [slicer](https://en.wikipedia.org/wiki/Slicer_(3D_printing)) designed specifically for [three.js](https://github.com/mrdoob/three.js) and inspired by the discussion on [this three.js issue](https://github.com/mrdoob/three.js/issues/17981). The idea is to be able to go straight from a mesh in a three.js scene to a machine usable [G-code](https://en.wikipedia.org/wiki/G-code), thus eliminating the need for intermediary file formats and 3rd party slicing software.
8-
95
<p align="center">
106
<a href="https://github.com/jgphilpott/polyslice/actions"><img src="https://github.com/jgphilpott/polyslice/actions/workflows/tests.yml/badge.svg" alt="Polyslice Tests"></a>
117
<a href="https://badge.fury.io/js/@jgphilpott%2Fpolyslice"><img src="https://badge.fury.io/js/@jgphilpott%2Fpolyslice.svg" alt="npm version"></a>
128
<a href="https://opensource.org/licenses/MIT"><img src="https://img.shields.io/badge/License-MIT-green.svg" alt="License: MIT"></a>
139
</p>
1410

11+
# Polyslice
12+
13+
An [FDM](https://en.wikipedia.org/wiki/Fused_filament_fabrication) [slicer](https://en.wikipedia.org/wiki/Slicer_(3D_printing)) designed specifically for [three.js](https://github.com/mrdoob/three.js) and inspired by the discussion on [this three.js issue](https://github.com/mrdoob/three.js/issues/17981). The idea is to be able to go straight from a mesh in a three.js scene to a machine usable [G-code](https://en.wikipedia.org/wiki/G-code), thus eliminating the need for intermediary file formats and 3rd party slicing software.
14+
1515
## Installation
1616

1717
### Node.js
@@ -125,9 +125,9 @@ slicer.codeArcMovement(...) // G2/G3 - Arc movement.
125125
slicer.codeBézierMovement([...]) // G5 - Bézier curves.
126126

127127
// Utilities
128-
slicer.codeMessage('Hello World!') // M117 - Display message.
129-
slicer.codeDwell(1000) // G4/M0 - Pause/dwell.
130-
slicer.codeWait() // M400 - Wait for moves to finish.
128+
slicer.codeMessage('Hello World!') // M117 - Display message.
129+
slicer.codeDwell(1000) // G4/M0 - Pause/dwell.
130+
slicer.codeWait() // M400 - Wait for moves to finish.
131131
```
132132

133133
## Examples
@@ -150,11 +150,11 @@ gcode += slicer.codeNozzleTemperature(210, true);
150150
gcode += slicer.codeBedTemperature(60, true);
151151

152152
// Draw square perimeter.
153-
gcode += slicer.codeLinearMovement(0, 0, 0.2, null, 3000); // Move to start.
154-
gcode += slicer.codeLinearMovement(10, 0, 0.2, 0.5, 1200); // Bottom edge.
155-
gcode += slicer.codeLinearMovement(10, 10, 0.2, 0.5, 1200); // Right edge.
156-
gcode += slicer.codeLinearMovement(0, 10, 0.2, 0.5, 1200); // Top edge.
157-
gcode += slicer.codeLinearMovement(0, 0, 0.2, 0.5, 1200); // Left edge.
153+
gcode += slicer.codeLinearMovement(0, 0, 0.2, null, 3000); // Move to start.
154+
gcode += slicer.codeLinearMovement(10, 0, 0.2, 0.5, 1200); // Bottom edge.
155+
gcode += slicer.codeLinearMovement(10, 10, 0.2, 0.5, 1200); // Right edge.
156+
gcode += slicer.codeLinearMovement(0, 10, 0.2, 0.5, 1200); // Top edge.
157+
gcode += slicer.codeLinearMovement(0, 0, 0.2, 0.5, 1200); // Left edge.
158158

159159
gcode += slicer.codeAutohome();
160160

@@ -267,12 +267,12 @@ npm run test:coverage # Run tests with coverage.
267267
Multiple build targets are supported:
268268

269269
```bash
270-
npm run build:node # Node.js builds (CommonJS + ESM).
271-
npm run build:browser # Browser build (IIFE).
272-
npm run build:cjs # CommonJS build only.
273-
npm run build:esm # ES modules build only.
274-
npm run build:minify # Minified builds.
275-
npm run build # All builds.
270+
npm run build:node # Node.js builds (CommonJS + ESM).
271+
npm run build:browser # Browser build (IIFE).
272+
npm run build:cjs # CommonJS build only.
273+
npm run build:esm # ES modules build only.
274+
npm run build:minify # Minified builds.
275+
npm run build # All builds.
276276
```
277277

278278
## Tools

package-lock.json

Lines changed: 13 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,8 @@
5656
},
5757
"dependencies": {
5858
"three": "^0.180.0",
59-
"@jgphilpott/polyconvert": "^1.0.1",
60-
"@jgphilpott/polytree": "^0.1.0"
59+
"@jgphilpott/polyconvert": "^1.0.2",
60+
"@jgphilpott/polytree": "^0.1.1"
6161
},
6262
"devDependencies": {
6363
"coffeescript": "^2.7.0",

0 commit comments

Comments
 (0)