å·²éè¿å®å ¨å å¯æ£æµ å¦æ没æèªå¨è·³è½¬ï¼è¯·ç¹å»ä¸æ¹æé®åå¾ ç¹å»è¿å ¥è´å½©ä¸å¿360å®å ¨å«å£«æä¾ææ¯æ¯æ Copyright ? 1998 -2020. All Rights Reserved.
 å·²éè¿å®å ¨å å¯æ£æµ å¦æ没æèªå¨è·³è½¬ï¼è¯·ç¹å»ä¸æ¹æé®åå¾ ç¹å»è¿å ¥è´å½©ä¸å¿360å®å ¨å«å£«æä¾ææ¯æ¯æ Copyright ? 1998 -2020. All Rights Reserved.
AngularJS ã«ã¦ã¼ãã£ãªãã£é¢æ°ããã«ã¯ãããã©ãé åããªãã¸ã§ã¯ããæä½ããé¢æ°ã足ããªãã®ã§ã Underscore.js ã使ããã¨ã«ããã AngularJS ãããä¾åæ§æ³¨å ¥ããããããUnderscope.js ã AngularJS ã¢ã¸ã¥ã¼ã«åãã¦ããã <!DOCTYPE html> <html ng-app="UnderscoreSample"> <head> <meta charset="utf-8"> <title>UnderscoreSample</title> </head> <body ng-controller="MainCtrl"> <ul> <li ng-repeat="value in values" ng-bind="value"></li> </ul> <script src="underscore.js"></script> <scrip
<img src="{{image}}"> app.controller('MainCtrl', function($scope) { $scope.image = 'path/to/image'; }); ã¨ãããå ´åãèªã¿è¾¼ã¿æã« {{image}} ã«ãªã¯ã¨ã¹ããé£ãã§404ã«ãªãã ng-srcã使ãã¨ãããããã <img ng-src="{{image}}">
One of the aspects of Angular that seems to appeal to a multitude of people is its opinions on how you structure an application. Usually we consider opinions to be bad, since developers don't want your ideas on what constitutes "correct" application architecture thrust upon them. In the case of JavaScript, it seems that there was a mass of folks waiting for someone - anyone - to have a strong opin
ãåãã¯ã¿ããªæ²³åèã ã®ã¢ãã¡å決å®ã«å°èºããã¦ãã seikichi ã§ãï¼ å¾ã¡ããããããâ¦â¦ï¼ åç½®ãã¯ãã¦ããï¼AngularJS ã®è©±ããã¾ãï¼ AngularJS ã¯ãã©ã¦ã¶ä¸ã§åä½ããWebã¢ããªã±ã¼ã·ã§ã³ãä½æããããã® JavaScript ãã¬ã¼ã ã¯ã¼ã¯ã§ãï¼Backbone.jsï¼Ember.jsï¼Knockout.js ãªã©ã«ä»£è¡¨ãããï¼æè¿æµè¡ã(?)ã®MV*ãã¬ã¼ã ã¯ã¼ã¯ã®1ã¤ã¨è¨ãã°è¯ãã®ã§ããããï¼ AngularJSã®å ¬å¼ãµã¤ã ã«æ²è¼ããã¦ãããµã³ãã«ãè¦ã¦ã¿ã¾ãï¼ ããã¹ãããã¯ã¹ã®å 容ãå¤æ´ããã¨ï¼<h1> è¦ç´ ã®ä¸èº«ã«ãªã¢ã«ã¿ã¤ã ã«åæ ããã¾ãï¼ ãããï¼JavaScript ãã¾ã 1è¡ãæ¸ãã¦ãªãã®ã«ï¼ä½ãä½ã£ãæ°åã«ãªã£ã¦ãã¾ãã¾ãã (ãããã)ï¼ AngularJS 㯠ãã¥ã¼ã§ã®å¤æ´ãã¢ãã«ã«ï¼ã¢ãã«ã§ã®å¤æ´ããã¥ã¼ã«èªåçã«åæ ãã
æåã« AngularJSã使ãå§ãã¦ï¼å¹´åãããæè¿ã§ã¯ã¾ã£ãã®ãã¹ã³ã¼ãç¶æ¿ã«ããå¤ã®åé¡ã§ããã ï¼ãAngularJSãã¹ã³ã¼ãã®ç¶æ¿ã§å°å³ã«ããããã¡ãªã㨠ã§ä¸å¯§ã«è§£èª¬ããã¦ãã¾ãï¼ ãããªæã«controllerAsã使ãã¨å¤ã®åé¡ãã解æ¾ãããããã¨æãã¦ãããã¾ããã controllerAsã®ä½¿ãæ¹ã¨æ¢åã³ã¼ãã«å°å ¥ããæ¹æ³ã調ã¹ã¦ãããã¡ã«ãèªåãæ¸ãã¦ããã³ã¼ãã§ã¹ã³ã¼ãã®ä½¿ãæ¹ãééã£ã¦ãããã¨ãæµ®ã彫ãã«ãªãã¾ããã ãã®è¨äºã§ã¯ãããªåé¡ç¹ã解æ¶ãã¤ã¤controllerAsã使ãæ¹æ³ã«ã¤ãã¦ç´¹ä»ãããã¨æãã¾ãã ã¹ã³ã¼ãã®ä½¿ãæ¹ã®ä½ãééã£ã¦ããã åé¡ã®ããã³ã¼ã // controller .controller('MainCtrl', ['$scope', function ($scope) { $scope.list = [{id:1}, {id:
ã¯ããã« ååã®ã¦ã§ããã¶ã¤ãã¼ãã¯ãããAngularJSï¼ngRouteã使ã£ãã·ã³ãã«ãªViewã®åãæ¿ãã§ngRouteã使ãã¾ãããä»åã¯ããé«æ©è½ãªAngularUI Routerã使ã£ã¦ã¿ã¾ããä»åã¯ngRouteã§ãã£ããã¨ã¨åããã¨ãAngularUI Routerã§ãã£ã¦ã¿ããã¨æãã¾ãã AugularUI Routerã¨ã¯ AngularUI Routerã¨ã¯ãngRouteã¨åãã«ã¼ãã£ã³ã°ã¢ã¸ã¥ã¼ã«ã®ã²ã¨ã¤ãngRouteã¯URLãå ã«ã«ã¼ãã£ã³ã°ãã¦ãã¾ããããAngularUI Routerã¯ç¶æ ï¼Stateï¼ãå ã«ã«ã¼ãã£ã³ã°ãè¡ãã¾ããState/Viewã®å ¥ãåãã§ããè¤æ°ã®Viewãä½ããã®ãç¹å¾´ã§ãã AngularUI Router Guide AngularUI Routerã¤ã³ã¹ãã¼ã« $ bower install angular-ui-r
æè¿ã«ããã©ã¼ã¡ã³ã«ç´è±ãå ¥ããã®ã好ãã§ãã«ããã©ã¼ã¡ã³ã«ç´è±3ããã¯ã¨ãããã£ã¨å ¥ãã¦ãããã«åµãå ¥ãã¦é£ã¹ããããã è¦ãç®ã¯æªããã©æå¤ã¨ãããã®ã§ãèå³ããæ¹ã¯ã試ãããã ã¨ããã§æè¿ã¯ Node.js ã¨ã express ã¨ã mongodb ã¨ã AngularJS ãåå¼·ä¸ã ãã¡ã ã®ãã¢ã¢ããªããã¼ã¹ã«ããããã¨ããã£ã¦å¤æ´ããªãããæåã確èªãã¤ã¤åå¼·ãã¦ããã©ãã©ããåå¼·ãå§ãã§ã¤ã¾ãããã¨ãå¤ãã ä»åã¯ãAngularJS ã§ãã¼ã¿ã®æ´æ°ããããã¨ããã¨ãã«ãexpress å´ã§ CSRF ã¨ã©ã¼ãåºãã®ã§ããã®å 容ã¨å¯¾å¦æ¹æ³ãã¾ã¨ãã¦ã¿ãã CSRF ã¨ã©ã¼ AngularJS ã§ãã¼ã¿æ´æ°ããããã¨ããã¨ãããexpress å´ã§ä¸è¨ã®ãããªã¨ã©ã¼ãåºãã Error: Forbidden at Object.exports.error (/home/n
6. æ¬æ¥ã話ããå 容 5 AngularJSã§å¯¾çã§ããèå¼±æ§ã¨ãã®å®è£ æ¹æ³ ⢠DOM Based XSS ⢠Cross-Site Request Forgery (CSRF) AngularJSã§ã¯å¯¾çã§ããªãèå¼±æ§ (ã¹ã³ã¼ãå¤) ⢠ãµã¼ãå´ã§ã®å¯¾çãå¿ è¦ã¨ãªãèå¼±æ§ â¢ ãã©ã¦ã¶ããããã³ã«ç±æ¥ã®èå¼±æ§ â»CSRFã¯ãµã¼ãå´ã§ã®å¯¾çãè¦ãã¾ããä»åã®çºè¡¨ã§ã¯ã¹ã³ã¼ãå¤ã¨ãã¾ã 8. XSSã®ç¨®é¡ ⢠ãµã¼ãå´ã§çºçããXSS - åå°åXSS - HTTPã®ãªã¯ã¨ã¹ãã«å«ã¾ããã¹ã¯ãªãããã ã¬ã¹ãã³ã¹ã®HTMLã«ãã®ã¾ã¾åãè¾¼ã¾ãããã¨ã§çºç - æç¶åXSS - HTTPã®ãªã¯ã¨ã¹ãã«å«ã¾ããã¹ã¯ãªãããä¸æ¦ãµã¼ãã«ä¿åããã ãã®ãã¼ã¿ãå ã«HTMLãåºåããéã«ã¹ã¯ãªãããåãè¾¼ã¾ãããã¨ã§çºç ⢠ã¯ã©ã¤ã¢ã³ãå´ã§çºçããXSS - DOM based XSS -
å æ¥ã®ng-mtg#4 AngularJS åå¼·ä¼ã§LTãããã¨æã£ããã©ç³ãè¾¼ã¿ãéã«åããªãã£ãã®ã§ããã°ã«æ¸ãã¾ãã å æãªãªã¼ã¹ãããAngularJS 1.2ã¯ã»ãã¥ãªãã£ããã°ã£ã¦ãçãªãã¨ãèããã®ã§ãã»ãã¥ãªãã£å¨ãã®ä»çµã¿ã調ã¹ã¦ã¿ã¾ããã ãé¡ã¯ä»¥ä¸ã§ãã CSRF JSON CSP (Content Security Policy) Escaping CSRF ã¦ãã¼ã¯ãªãã¼ã¯ã³ãHTTPãªã¯ã¨ã¹ãã«è¼ãã¦ãµã¼ãã¼ã§ãã§ãã¯ãã対å¿ãä¸ã®ä¸ã§ã¯ä¸»æµï¼æè¿ã¯ã«ã¹ã¿ã ãããã®ãã§ãã¯ã«ãã対çãï¼ AngularJSã§ã¯ãXSRF-TOKEN Cookieã«ãã¼ã¯ã³ãè¼ã£ã¦ããã¨ã$httpã使ã£ãHTTPãªã¯ã¨ã¹ãã®ãããã«èªåçã«X-XSRF-TOKENãããã¼ãä»ãã XSRF-TOKEN Cookieã¯ãã¡ããNot HttpOnlyã§ã Angularçã§ã¯CS
èæ¯AngularJSã§ã®$locationã使ãã¨ãã«èªåã®ç解ãééã£ã¦ãã¦ããããããã£ãã®ã§ã¡ã¢ã£ã¨ãã¾ãã åæ ä»åã¯ãã°ã¤ã³ç»é¢(/login)ã表示ãã¦ããã°ã¤ã³ã§ããããã¼ã ç»é¢(/home)ã表示ããã¨ããä¾ã ãã°ã¤ã³å¦çèªä½ã¯ããµã¼ããµã¤ãã®APIã«Ajaxã§POSTï¼JSONï¼ãã¦èªè¨¼å¦çããã¾ãã APIãå©ããµã¼ãã¹ã¯ä»¥ä¸ã®éãã ajaxã§ãªã¯ã¨ã¹ããæãã¦ãçµæãããã¼ããã£ã¹ããã app.service('authService', [ '$rootScope', function($rootScope) { this.login = function(user) { $.ajax({ type : 'POST', url : '/app/api/login', contentType : 'application/json', data : JSON
AngularJS ã®åå¼·ãå§ãã¾ããã æåã¯ãã®ããã°ã©ãã³ã°ã«é¢ããç¬ç¹ã®ãç´æäºé ã«ã¤ã©ãã¨ãã¾ãããããã¢ã§ããã DI ããçãªé¢ä¿ã®ã¯ã©ã¹ãï¼å®è¡æã«ï¼çµã³ã¤ããã®ã«å¿ è¦ãªä»çµã¿ãã¨å²ãåããDI â ç¿ã§ãåãã! Dependency Injection: ä¾åæ§ã®æ³¨å ¥ ã§å¼ç¨ããã¦ãã ITpro è¨äº ã® ã¯ã©ã¹å³ ãã³ã¼ãããæ³åã§ããããã«ãªã£ãã¨ããã§ããããªãã«é¢ç½ããªã£ã¦ãã¾ããã ä½ãããjQuery ãè¦ããªããªãï¼ãã®ãã¨ã£ã¦ãå¿«æãªãã§ã ï¼ã¤ããæããããã©â¦ï¼ã ãã¦ä»åã¯ãjQuery ã¾ã¿ãã®ãã¼ã¸ã AngularJS ã§æ¸ãæããæã«æ°ä»ãã Ajax ã®åä½ â éåæéä¿¡ã®æ»ãå¤ããã¤ã©ã㧠DOM ã«åæ ããã â ã«é¢ãã話é¡ãæ¸ãã¦ã¿ã¾ãã jQueryã®å ´å æ¤ç´¢ã®ã¯ã¨ãªã渡ã㨠Github ã®ãªãã¸ããªãè¿ãé¢æ°ãä¾ã«ã¨ã£
 å·²éè¿å®å ¨å å¯æ£æµ å¦æ没æèªå¨è·³è½¬ï¼è¯·ç¹å»ä¸æ¹æé®åå¾ ç¹å»è¿å ¥è´å½©ä¸å¿360å®å ¨å«å£«æä¾ææ¯æ¯æ Copyright ? 1998 -2020. All Rights Reserved.
æè¿ angularJS ã«å¯¾ããæå¾ ã®ä½ä¸ãèããã¦ã¤ããã ãªãã ããã 㧠SPA ãã jQuery ã«æ»ã£ã話 - ãã¯ã³ã³ Angularã®åé¡ã§ã¯ ã¯ã¦ãªããã¯ãã¼ã¯ - mizchi ã®ããã¯ãã¼ã¯ - 2015å¹´5æ18æ¥ ã¿ããªä½¿ãã©ãããééã£ã¦ããããï¼å¹´åããã使ã£ã¦ã¦ä¸æºããããã©èªåã®ãã使ãç¯å²ã§ã¯ angularJS æå¼·ã ã¨æãã angularJS ãåãã¦ãã®ã¯ Single Page Application ã§ã¯ãªã angularJS ãåãã¦ãã®ã¯ â ãã©ã¼ã ã®ãããªç´°ããé¨åãå¤ç¨ ï¼ DOMããªã¼ã¨ãã¼ã¿ã¹ã³ã¼ããã»ã¼ä¸è´ãã¦ãã¦ã¦ã¼ã¶ã®å ¥åããµã¼ãã«éã£ãããã webã¢ããªã管çç»é¢ããã¤ãã¼ã¸ãæ¥åã¢ããªãªã© â³ Single Page Application â ç°¡åã«ä½ãããã©ãã¼ã¸éã®é£æºãå¿ è¦ãªããªããµã¼ãå´ã§åãã¦ãã¾ã£ãæ¹
è»è¼ªéçºå¤§å¥½ãããããã§ããããã«ã¡ã¯ãï¼æ¨æ¶ï¼ ä»åã¯ãç»é¢é·ç§»æã«ã³ã³ããã¼ã©ãè·¨ãã§å¤ãåã渡ãæ¹æ³ãã¾ã¨ãã¦ã¿ã¾ããããè¯ããã¨ãããä¾ãããã°ããæªããã¨æãããä¾ãããã¾ããããä»ãåããã ããã èªåã°ãã¼ãã«ãªãã¸ã§ã¯ãã使ã ããæå³ã§æå¼·ãªã°ãã¼ãã«ãªãã¸ã§ã¯ã ( ãããã¬ãã«ã®ãªãã¸ã§ã¯ã ) ã§ãããä»åã®ãããªä¾ã§ä½¿ç¨ããå ´åããã¼ã å ã®ã³ã¼ãã¬ãã¥ã¼ã§ã説æããããã¨ããããã ãµã³ãã« ä¸å¿ããµã³ãã«è²¼ã£ã¦ããã¾ãã( çä¼¼ãããã¨ã¯ãå§ããã¾ãã ) ã½ã¼ã¹ ã·ã³ã¿ãã¯ã¹ãã¤ã©ã¤ããããããªãã¨ã«ãªã£ã¦ãã¾ãç ´å£å⦠var Globals = {}; // ('A`) (function () { angular.module('appName', ['ngRoute'], function($routeProvider) { $routeProvide
ãªãªã¼ã¹ãé害æ å ±ãªã©ã®ãµã¼ãã¹ã®ãç¥ãã
ææ°ã®äººæ°ã¨ã³ããªã¼ã®é ä¿¡
å¦çãå®è¡ä¸ã§ã
j次ã®ããã¯ãã¼ã¯
kåã®ããã¯ãã¼ã¯
lãã¨ã§èªã
eã³ã¡ã³ãä¸è¦§ãéã
oãã¼ã¸ãéã
{{#tags}}- {{label}}
{{/tags}}