psd.js icon indicating copy to clipboard operation
psd.js copied to clipboard

Failed to compile.

Open CachCheng opened this issue 4 years ago • 5 comments

Failed to compile.

./node_modules/psd2json/node_modules/psd/lib/psd.coffee Module parse failed: Unexpected character '#' (1:0) You may need an appropriate loader to handle this file type. | # A general purpose parser for Photoshop files. PSDs are broken up in to 4 logical sections: | # the header, resources, the layer mask (including layers), and the preview image. We parse | # each of these sections in order. @ ./node_modules/psd2json/node_modules/psd/index.js 2:17-44 @ ./node_modules/psd2json/index.js @ ./src/main.js @ multi (webpack)-dev-server/client?http://localhost:8080 webpack/hot/dev-server ./src/main.js

CachCheng avatar Nov 10 '20 07:11 CachCheng

I appear to be having the same issue. Have you or anyone else discovered a fix for this?

zavalzam avatar Nov 15 '20 23:11 zavalzam

I appear to be having the same issue. Have you or anyone else discovered a fix for this?

What's your problem?I haven't now

CachCheng avatar Nov 16 '20 02:11 CachCheng

Same problem for me...working with webpack as well.

cathyhax avatar Feb 08 '21 19:02 cathyhax

@cathyhax for me, the problem ended up being that I was using an outdated version of the module. When installing the package with npm, run "npm install psd.js" instead of just "npm install psd". Just seems like the documentation on here is outdated, but after installing the correct version, it has been working just fine for me.

zavalzam avatar Feb 08 '21 20:02 zavalzam

@zavalzam Thank you! I have just found the same as well. Very confusing as I think there are many branches of this repo on npm.

cathyhax avatar Feb 08 '21 21:02 cathyhax