【问题标题】:How to configure react, jsx, and babel in Visual Studio Code?如何在 Visual Studio Code 中配置 react、jsx 和 babel?
【发布时间】:2016-09-08 10:39:18
【问题描述】:

我想开始使用 jsx 和 Babel 学习 ReactJs。我的编辑器是 Visual Studio Code。我需要将它们配置为在 VSCode 中协同工作,但在 Google 和 StackOverFlow 中搜索后,我发现不同框架和平台的内容分散。是否有任何资源可以逐步学习配置并在 VSCode 中使用反应?

非常感谢

【问题讨论】:

    标签: reactjs visual-studio-code react-jsx babeljs


    【解决方案1】:

    我在 GitHub 中找到了 babel-standalone。

    babel-standalone 是 Babel 的独立版本,用于非 Node.js 环境,包括浏览器。它与所有标准 Babel 插件和预设捆绑在一起,并且还可以选择构建 babili (babel-minify)。

    使用 babel-standalone,我们可以在浏览器中编译出 jsx 格式的 JavaScript 文件。易于安装和使用。

    【讨论】:

    • 这没有回答问题(我也有同样的问题):“有没有资源可以逐步学习配置并在 VSCode 中使用反应?”不是,“我在哪里可以下载 Babel。”
    猜你喜欢
    • 2016-06-14
    • 2021-03-06
    • 2017-01-30
    • 1970-01-01
    • 2019-11-06
    • 2023-01-17
    • 2021-06-26
    • 2021-09-16
    • 1970-01-01
    相关资源
    最近更新 更多