Basic error when using jquery with nodejs

后端 未结 4 1566
情话喂你
情话喂你 2021-01-14 07:01

I\'m trying to use some jquery in my project and as soon as I tried using it I came across an error in copied code and can\'t get any google help on it

 var          


        
4条回答
  •  粉色の甜心
    2021-01-14 07:26

    It used to work just fine for many months. But then they changed something and now it doesn't. I could run jquery without a window just fine and it worked perfectly on node js. But not with the latest version for some reason. Really weird.

    What we are trying to do is just this:

    $ = require("jquery"); $("..).find(".message").html("Hello World!");

提交回复
热议问题