2
personal I’m having a problem related to angular router ui always when the use cannot make it work, I copy the code exactly the way it is in the git of uiRouter and it does not work, because the links are not referential , when I pass the mouse over the link the format of the mouse is as if I were passing ito over normal text and not over a link. Could someone please help ? thank you in advance
<html>
<head>
<script src="node_modules/angular.js"></script>
<script src="node_modules/angular-ui-router.js"></script>
<script src="helloworld.js"></script>
<style>.active { color: red; font-weight: bold; }</style>
</head>
<body ng-app="helloworld">
<a ui-sref="hello" ui-sref-active="active">Hello</a>
<a ui-sref="about" ui-sref-active="active">About</a>
<ui-view></ui-view>
var myApp = angular.module('helloworld', ['ui.router']);
myApp.config(function($stateProvider) {
var helloState = {
name: 'hello',
url: '/hello',
template: '<h3>hello world!</h3>'
}
var aboutState = {
name: 'about',
url: '/about',
template: '<h3>Its the UI-Router hello world app!</h3>'
}
$stateProvider.state(helloState);
$stateProvider.state(aboutState);
});
Has the question been answered? You need the answer to be improved?
– Jéf Bueno