简体   繁体   中英

Onsen UI not working in AngularJS project

Im trying to use Onsen with AngularJS but when i call the scripts i have error of 404 not found, this are the scripts that arent working

<link rel="stylesheet" href="onsenui.css"/>
<link rel="stylesheet" href="onsen-css-components.css"/>
<script src="angular.min.js"></script>
<script src="onsenui.min.js"></script>
<script src="angular-onsenui.min.js"></script>

i have installed onsen ui with npm, and i do have it in the node modules, and i have called it in the module too

var app = angular.module('app',['ngRoute','app.routes', 'app.core', 
'onsen']);
app.controller('AppCtrl',function(){});

any idea what can i do to make it work?

No need to call this via script tag if you already have installed via NPM.

Take advantage of the module distribution, so you can simply call it with requirejs .

But there is literally gazillion projects on the web. For example this boilerplate can help you.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM