Giter Site home page Giter Site logo

Comments (10)

fulls1z3 avatar fulls1z3 commented on May 4, 2024

@theomathieubhvr without repro steps it would be very difficult to see what's going on. I'll try to have a look on this when I'll be available.

from universal.

theomathieubhvr avatar theomathieubhvr commented on May 4, 2024

Yes I understand. I'll try to repro this on monday !

Thanks.

from universal.

theomathieubhvr avatar theomathieubhvr commented on May 4, 2024

Ok,

I succeeded repro this :)

I THINK it might be starting when I run npm run build:universal-prod, then my hmr command does not work anymore.

This is what I did :

$ git clone ...
$ npm run build:spa-dev (to build index.html for the first time, or else hmr does not work).
$ npm run serve:spa-hmr

MODIFY A FILE : HMR WORKS

$ Ctrl-C
$ npm run build:universal-prod
$ node .server/server.js

MODIFYING A FILE DOES NOT WORK BEYOND THIS POINT.

$ npm run serve:spa-hmr

=> even when deleting .cache, .temp directories, any change is not taken into account (event if I change a file BEFORE running serve:spa-hmr).

Thanks :)

from universal.

fulls1z3 avatar fulls1z3 commented on May 4, 2024

@theomathieubhvr now I get it :)

The HMR feature does not run on the server platform (Universal) yet. I've got it working just on the browser platform (SPA). Let's keep this issue open, because I'm still working on development of polyfills for Angular Material for the server platform. Then, I'll surely have a look at this.

from universal.

theomathieubhvr avatar theomathieubhvr commented on May 4, 2024

Oh, that's not what I meant. I don't want hmr to work with universal. But in my case :

  • I run hmr for development mode
  • I run build:universal-prod for production mode

But one at a time !

Once I runned build:universal-prod to build my project for production, I cannot develop anymore cause my files are not updated anymore.

from universal.

fulls1z3 avatar fulls1z3 commented on May 4, 2024

Now more clear, the HMR implementation was only for the development mode (JiT), and on browser platform (SPA).

from universal.

fulls1z3 avatar fulls1z3 commented on May 4, 2024

And I want to simply ask about files not updated anymore. You mean, the assets which were copied thru CopyWebpackPlugin?

from universal.

theomathieubhvr avatar theomathieubhvr commented on May 4, 2024

I've not tried the assets (I can try any file if you ask me) but modifying app.component.html does not update the view.

from universal.

fulls1z3 avatar fulls1z3 commented on May 4, 2024

Understood, assets just add a bit more complexity to the current situation. But the previous answer is still valid, you can get the HMR running only after a development build, not a production build.

However, I'll see what can I do for this.

from universal.

theomathieubhvr avatar theomathieubhvr commented on May 4, 2024

Oh ok now I understand !!

I have to run build:spa-dev to rebuild the correct files.

As always, thanks for your reactivity ! :)

from universal.

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.