Comments (8)
Closing issue since it seems to have been a Vite issue. Specifically, Vite uses ESbuild in development and then ESbuild was reordering the class RequestPoolManager
definition and converting it to a variable which broke hoisting.
Excluding @cornerstone/core
and then using vite-plugin-commonjs
helped fix it for now.
from cornerstone3d.
I ran into the same issue today. Could you please explain your solution a little bit further? I installed vite-plugin-commonjs
and added it to my vite.config.js
file:
optimizeDeps: {
exclude: ['@cornerstonejs/tools', '@cornerstonejs/core'],
esbuildOptions: {
plugins: [
esbuildCommonjs(['@cornerstonejs/tools', '@cornerstonejs/core'])
]
}
},
plugins: [
vue(),
viteCommonjs()
]
But it does not work for me. What exactly does the correct configuration look like?
I would greatly appreciate any help. Thank you.
from cornerstone3d.
Ended up not using cornerstone for performance reasons, so I'm just browsing through old code to see what might work.
Try this:
{
define: {
global: {}
},
build: {
minify: false,
},
plugins: [
vue(),
viteCommonjs(),
],
optimizeDeps: {
exclude: ['@cornerstonejs/core']
}
}
from cornerstone3d.
Hello, I'm having the same error, I already applied this changes, but now I'm getting and error with other dependencies that cornerstone use like globalThis, how did you solve that? because I'm unabled or running the project.
from cornerstone3d.
the above is not a standard solution, but also depends on the framework support
from cornerstone3d.
@LSanchez94 me too? what do you solve this?
from cornerstone3d.
@LSanchez94 me also facing the same error. are you solve this or use similar anything?
from cornerstone3d.
@richardc-zapsurgical hey I use your mentioned configuration. but now I am getting an error with other dependencies that is cornerstone use globalThis, how did you solve that? I am not found any solution. Please help.
from cornerstone3d.
Related Issues (20)
- [Bug] Strange Visualization of DICOM HOT 2
- [Bug] StackViewport not cancelling scroll debounce timer when the Image Set is not fully Loaded HOT 1
- [Bug] Desired resource size is greater than max texture size HOT 2
- [Bug] Issue in runtime useing @vue/cli-service building tool after upgrade cornerstone libs. HOT 2
- [Bug] Contour's color is wrong HOT 17
- Nifti scroll problem
- [Bug] Memory Leaks on inter cpu computer HOT 3
- [Bug] Volume viewport synchronization - Couldn't handle volume viewport synchronization for different viewports (Sagittal, axial and coronal)) HOT 3
- [Bug] After using compression, DICOM files rendereed as brighter HOT 2
- [Bug] When using @cornerstonejs/tools with electron or SPA Vue+vite, production application crash HOT 3
- [Bug] generateVolumePropsFromImageIds allocates an Int16Array if rescale or intercept is negative, which is incompatible with texSubImage3D HOT 1
- [Feature Request] How do I render a TAG pixel in Dicom with a TAG Value of 6000,3000 HOT 5
- Image Loader - cancelLoadAll() errors when no imageId's in request pool. HOT 1
- [Bug] When I have a lot of contourSegments displayed, the pagination of the image becomes sluggish HOT 1
- [Bug] 使用volumeLoader.registerVolumeLoader("nifti", cornerstoneNiftiImageVolumeLoader);加载图像出现Bug HOT 2
- [Bug] How to resolve "Multiple segmentation representations detected for this tool group. The first one will be used." HOT 1
- [Bug] First image rendered by the volume loader is not the first instance in series HOT 2
- [Bug] fix(metaData Types): change { any } to any type HOT 1
- [Bug] StackViewport.setImageIdIndex should set this.targetImageIdIndex too HOT 1
- Image display blur
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 cornerstone3d.