requirejs及vue的使用

//index.html

<!DOCTYPE html>

<html>

<head>

    <meta charset="UTF-8">

    <title>Title</title>

    <script async type="text/javascript" data-main="script/main" src="//cdn.bootcss.com/require.js/2.3.3/require.js"></script>

</head>

<body>

    <div id="app">

        <router-link to="/foo">Go to Foo</router-link>

        <router-view></router-view>

    </div>

</body>

</html>

https://img2.mukewang.com/5c29dd590001c4d907660662.jpg

浏览器报错

https://img1.mukewang.com/5c29dd730001158516910198.jpg

vue-router,请问是不是写法不对,谢谢

慕雪6442864
浏览 474回答 1
1回答

Smart猫小萌

Vue.use(VueRouter)
打开App,查看更多内容
随时随地看视频慕课网APP

相关分类

JavaScript