Skip to content

Commit

Permalink
bump version to 1.0.7
Browse files Browse the repository at this point in the history
  • Loading branch information
zenozeng committed Jun 14, 2021
1 parent f4ce71b commit bb30ced
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 13 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## v1.0.7

- feat: sync element's width and height to context ([email protected])
- test: add test for loadFont, fixes #147

## v1.0.6

- fix: use encodeURIComponent when saving svg, fixes #176 (save() bug)
Expand Down
24 changes: 12 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ and manipulating existing SVG file without rasterization.

```html
<script src="https://unpkg.com/[email protected]/lib/p5.js"></script>
<script src="https://unpkg.com/[email protected].6"></script>
<script src="https://unpkg.com/[email protected].7"></script>
```

Open your sketch.js and edit it:
Expand Down Expand Up @@ -71,19 +71,8 @@ p5.RendererSVG is a class which extends p5.Renderer2D.
A mocked \<canvas\> element and a CanvasRenderingContext2D api are provided using [svgcanvas](https://github.com/zenozeng/svgcanvas),
which is JavaScript Object that syncs proprieties and draws on \<svg\> element.

## Building dist

To build dist files after cloning repo, you can run:

```bash
npm install
npm run build
```

## Known issue

### blendMode is not implemented yet.

### Too many child elements

Since SVG is XML-based, every call of the draw function will insert elements into it, and these elements keep existing even if they are not visible. So, long-time running will result in too many child elements. We recommend calling clear() in your draw function, which will trigger internal context.__clearCanvas() to remove elements.
Expand All @@ -97,6 +86,17 @@ function draw() {

See https://github.com/zenozeng/p5.js-svg/issues/32

### blendMode is not implemented yet.

## Building dist

To build dist files after cloning repo, you can run:

```bash
npm install
npm run build
```

## Tests

p5.SVG was driven by tests.
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "p5.js-svg",
"version": "1.0.6",
"version": "1.0.7",
"main": "./src/index.js",
"scripts": {
"start": "python3 -m http.server 3000",
Expand Down

0 comments on commit bb30ced

Please sign in to comment.