我可以怎样混合使用jQuery和Vanilla JavaScript [英] In what ways can I mix jQuery and vanilla JavaScript
问题描述
我有一个使用香草JavaScript编写的Web应用程序.我想用jQuery动画来增强它,并使用一些我在各种jQuery插件中发现的功能,例如 Uploadify .有什么可能将jQuery混合到原始JavaScript中?我需要使用单独的脚本标签或单独的文件吗?我可以简单地将用jQuery语法编写的代码行插入到普通JavaScript的各个部分中吗?
I have a web application, written in vanilla JavaScript. I'd like to enhance it with jQuery animations and use a few features which I've found in various jQuery plugins, such as Uploadify. In what ways is it possible to mix jQuery into vanilla JavaScript? Will I need to use separate script tags or separate files? Can I simply insert lines of code written with jQuery syntax into sections of plain JavaScript?
谢谢
推荐答案
您无需执行任何特殊操作. jQuery只是Javascript函数和方法的库-它是普通Javascript.
You don't have to do anything special. jQuery is just a library of Javascript functions and methods -- it is ordinary Javascript.
这篇关于我可以怎样混合使用jQuery和Vanilla JavaScript的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!