Comments (9)
Heads up for others with this issue, it seems like just using
import { isCustomElement, transformAssetUrls } from "vue3-pixi/compiler" // <-- note the `/compiler` here
does the job.
from vue3-pixi.
similar situation
from vue3-pixi.
Can you provide versions such as Vue and pixi.js ? @NONAME00X
from vue3-pixi.
Can you provide versions such as Vue and pixi.js ? @NONAME00X
All my dependencies below
"pixi.js": "^7.4.0",
"screenfull": "^6.0.2",
"unplugin-auto-import": "^0.17.5",
"unplugin-vue-components": "^0.26.0",
"vue": "^3.3.11",
"vue3-pixi": "^0.9.0"
from vue3-pixi.
@hairyf
my current versions:
vue3-pixi: ^0.9.0
pixi.js: ^7.4.0
vue: ^3.3.4
vite: ^4.4.5
node: 20.11.0
If I use vue3-pixi: 0.8.4
and pixi.js: 7.3.2
, then yarn dev
works fine
from vue3-pixi.
I have the same situation with Node 20.11.0 || 18.19.0
"pinia": "^2.1.4",
"pixi.js": "^7.4.0",
"vue": "^3.3.4",
"vue-router": "^4.2.4",
"vue3-pixi": "^0.9.0"
failed to load config from \vite.config.js
error when starting dev server:
ReferenceError: Worker is not defined
from vue3-pixi.
@hairyf
See that pixijs/pixijs#10170
pixi.js does not run natively in Node.js, it's browser only. If you need to run in Node.js, you can use this project: https://github.com/pixijs/node
because when you try to compile the npm run dev it does not recognize it
from vue3-pixi.
@hairyf This seems to be a side-effect of how the docs for vue3-pixi
import the functions used for vite.config.ts
. Apparently too much of pixi is imported in the vite config, vite tries to compile it in node, and it crashes.
import { defineConfig } from "vite";
import vue from "@vitejs/plugin-vue";
import { isCustomElement, transformAssetUrls } from "vue3-pixi"; // <-- this right here
// https://vitejs.dev/config/
export default defineConfig({
plugins: [
vue({
template: {
compilerOptions: {
isCustomElement,
},
transformAssetUrls,
},
}),
],
});
Without that import from vue3-pixi
the dev server (or build) starts, but with it, the ReferenceError
appears.
from vue3-pixi.
@senritsu Thank, I will merge him
from vue3-pixi.
Related Issues (20)
- Error while installing vue3-pixi-nuxt
- Tiling Sprite Doesn't work when using local files not from a CDN HOT 2
- Does it support gif image? HOT 2
- demo can't be viewed HOT 1
- missing props in Application Component HOT 2
- repeated loading of loader component HOT 3
- could you include pixi-ui ? HOT 12
- (feature request) Component name prefix HOT 2
- Nuxt3 Example HOT 6
- Using vuex on children components of Application
- Error when trying to run Vite HOT 1
- PIXI.js 8 version with WebGPU HOT 3
- No PIXI Application found HOT 1
- Types don't seem to work with Pixi >= 7.3.0
- How to use Pixi UI HOT 1
- gl.getInternalformatParameter is not a function. HOT 3
- optimization of composition-api Based on Injection
- dev tools
- upgrade to vue3.4 gets Vue warn -> Failed to resolve vue3-pixi components HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vue3-pixi.