架子

2017-04-23  本文已影响0人  c59ffede9db6
<!DOCTYPE html>
<html ng-app='test'>
  <head>
     <meta charset="utf-8">
     <title>angular</title>
     <meta name="viewport" content="width=device-width,initial-scale=1.0,
     maximum-scale=1.0,minimum-scale=1.0,user-scalable=no">
     <link rel="stylesheet" type="text/css" href="static/css/reset.css">
     <script src="bower_components/angular/angular.js" charset="utf-8"></script>
     <script >
       var app=angular.module('test',[])
       app.filter('abc',function{
         return function(input){
           return input
         }
       })
       app.derective('showmore',function(){
         return {
           restrict:'E',
           template:`<span ng-transclude></span>`,
           replace:true,
           transclude:true
         }
       })
       app.controller('zhangsan',function($scope,$http){

       })
     </script>
 </head>
 <body ng-controller='zhangsan'>
  <h1>hello world</h1>
 </body>
</html>


上一篇 下一篇

猜你喜欢

热点阅读