Coder Social home page Coder Social logo

Comments (3)

ruanyf avatar ruanyf commented on May 20, 2024

webpack 打包生成的是 vendor.js 和 bundle.js

from webpack-demos.

lczxhf avatar lczxhf commented on May 20, 2024

不好意思!字母不知道都变成中文的! 我重新发一遍:

你好!我试了您的demo13!但是有些疑问!

1.您在outfile里面最后生成了两个js文件。一个是vendor.js,一个是bundle.js
但是vendor里面就已经包含了jquery的!,
同时您又在main.js里面又require了jquery,所以的话,bundle.js里面也包含了jquery!
这样不会重复了吗?


2.我去掉了demo13里面main.js里面的 var $= rquire("jquery") 但是报了一个错就是$ 未定义

请问可以帮我解答一下吗?谢谢

from webpack-demos.

ruanyf avatar ruanyf commented on May 20, 2024

你看一下 bundle.js 就明白了,它不包含 jQuery 的。

from webpack-demos.

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.