angularjs

    1熱度

    1回答

    您好,我有兩個angularjs文件的第一個1是控制器和第二個是工廠的功能,但它提供了一個unpr錯誤 工廠文件 var app = angular.module('basicApi',[]); app.factory('webApi',function($http,$q,$scope){ return { login : function(data){ re

    0熱度

    1回答

    這是一個普遍的問題。 通常,我們在Angular中編寫的任何代碼都會被編譯成一個捆綁文件,並將其傳遞給瀏覽器?我們編寫的JavaScript代碼在查看源代碼時可以看到,因爲它在包文件中。我們如何防止我們的代碼被傳播。是否有任何混淆器可以實時保護我們的算法?

    2熱度

    3回答

    我是angularjs中的新成員,並且作爲啓動器,我在訪問外部對象然後函數時遇到問題。我創建了一個工廠: var injectParams = ['$http']; var address = function ($http) { var factory = {}; factory.get = function() { return $http({

    0熱度

    1回答

    嘿,我有按鈕功能ng-click如何更改指令控制器中的屬性$ scope.actual? demo https://codepen.io/Turqus/pen/WXKvYM

    -2熱度

    1回答

    我有從API中提取對象的服務。某些對象可能包含圖片網址。後端正在掃描這些內容,並通過get_file_contents()處理它們(在PHP中)並將它們轉換爲內嵌數據。這大大加載了我服務器上的吞吐量。我這樣做的原因是因爲我想稍後緩存圖片以便脫機,但是仍然可以使用常規角度來呈現對象。 我不能因爲託管圖像的網站阻止跨站點請求與$http.get()做處理在Javascript在瀏覽器中。然後,我想要做

    2熱度

    2回答

    我已經在那裏我用NG-重複,讓我回 <div> <div class="col-sm-3" ng-repeat="el in vm.filmovi " id="filmovi"> <img src="http://image.tmdb.org/t/p/w500/{{el.poster_path}}" style="width:100%;"><br> <a

    -2熱度

    1回答

    我見過Restful API facotires錯誤處理的不同示例,這有點令人困惑。下面是兩個例子: 一個 angular.module('app').controller('userCtrl', function($scope, User) { $scope.users = []; $scope.error = ''; User.getUsers().then(f

    1熱度

    1回答

    我有一個簡單的前端應用程序,可以找到here。在我的索引文件我加載app.js先authentication.js服務: <script src="scripts/app.js"></script> <script src="scripts/services/authentication.js"></script> 認證模塊可以在scripts/services/authentication

    0熱度

    1回答

    我想根據他們的ID來訂購一些鋰。 目前我有: <ul bx-slider="" id="rotator" style="width: auto; position: relative;"> <li class="promo-banner ng-scope" ng-repeat="feature in events | limitTo:2" bx-slider-item="

    0熱度

    1回答

    我在嘗試本地創建新的JSON文件時出現404錯誤。 這裏是我的服務: eventsApp.factory('eventData', function($resource){ var resource = $resource('/data/event/:id', {id:'@id'}); return { getEvent: function(