Giter Site home page Giter Site logo

Cannot load images about electrode HOT 8 CLOSED

electrode-io avatar electrode-io commented on May 6, 2024
Cannot load images

from electrode.

Comments (8)

jchip avatar jchip commented on May 6, 2024

Thanks, a few issues in the generator have been fixed and this was one of them, but the boilerplate still has them since it was generated a while back. Will be manually fixing this boilerplate soon.

from electrode.

jchip avatar jchip commented on May 6, 2024

the material-ui sample app actually has the image fix https://github.com/electrode-io/electrode-react-sample-material-ui

from electrode.

jchip avatar jchip commented on May 6, 2024

To get isomorphic images working, update server/index.js with this https://github.com/electrode-io/electrode-react-sample-material-ui/blob/master/server/index.js#L38-L40.

from electrode.

ananavati avatar ananavati commented on May 6, 2024

fixed in
pr: #32

https://github.com/electrode-io/electrode-boilerplate-universal-react-node/blob/master/server/index.js#L58-L60

from electrode.

rbudiharso avatar rbudiharso commented on May 6, 2024

The isomorphic loader works only for development, it doesn't run after you run gulp build and gulp server-prod the images are not showing. Here's how to reproduce it:

git clone https://github.com/electrode-io/electrode-boilerplate-universal-react-node.git
cd electrode-boilerplate-universal-react-node
npm install
gulp build
NODE_ENV=production gulp server-prod

screenshot from 2016-11-04 10-40-36

from electrode.

EternallLight avatar EternallLight commented on May 6, 2024

Hi,

I'm having a similar issue with electrode on Mac out of the box with a new app with totally default settings:

<my project path>/src/client/images/electrode.png: Unexpected character '�' (1:0)
> 1 | �PNG
    | ^
  2 | 
  3 | 
  4 | IHDRHU�GgAMA��

I tried other PNG or JPG files and they all cause the same error.

Node JS version: v9.11.2

What can you suggest to resolve the issue?

from electrode.

thiagoneves avatar thiagoneves commented on May 6, 2024

I´m facing the same problem.

<my project path>/src/client/images/electrode.png: Unexpected character '�' (1:0)

How can i fix it?

from electrode.

EternallLight avatar EternallLight commented on May 6, 2024

@thiagoneves

For me, it was because I tried to used Express instead of Hapi. With Hapi, I also had that error, but at some point it was gone, and I don't know what changed. It just started working for all newly generated projects.

from electrode.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.