Hi, I finally reached the final steps of my app (11bc2ed5), everything works great on browser view but when I made a build the app do not show any resources hat should be retrieved by the ngResource.
A quick look to my resources.js:
angular.module(‘starter.services’, [])
.factory('Resources', ['$resource',
function($resource){
return {
Produits: $resource('http://example.com/getproduits/',{}, {
'query': { method:'GET', isArray:true, responseType:'json' }
}),
Recettes: $resource('http:/example.com/getrecette/v100/',{}, {
'query': { method:'GET', isArray:true, responseType:'json' }
}),
Recette: $resource('http://example.com/getrecette/v100/:id',{id: '@id'}, {
'get': { method:'GET', isArray:false, responseType:'json' }
})
}
}]
)
My model (app.js)
angular.module('starter', ['ionic', 'starter.controllers', 'starter.services','ngResource'])
The scripts from index.html:
<script src="lib/ionic/js/ionic.bundle.js"></script>
<script src="lib/ionic/js/angular-resource.min.js"></script>
<script src="cordova.js"></script>
<!-- your app's js -->
<script src="js/app.js"></script>
<script src="js/controllers.js"></script>
<script src="js/services.js"></script>
The Ionic.project:
{
"name": "CeliaLib",
"app_id": "11bc2ed5",
"gulpStartupTasks": [
"sass",
"watch"
],
"watchPatterns": [
"www/**/*",
"!www/lib/**/*"
]
}
And the Package.json:
{
"name": "CeliaLib",
"version": "1.0.0",
"description": "CeliaLibrary: An application that help people with celiac disease to in knowing whether a specific product is authorised for consuming or not. The Application has a library of special recipes for people with celiac disease.",
"dependencies": {
"gulp": "^3.5.6",
"gulp-sass": "^1.3.3",
"gulp-concat": "^2.2.0",
"gulp-minify-css": "^0.3.0",
"gulp-rename": "^1.2.0"
},
"devDependencies": {
"bower": "^1.3.3",
"gulp-util": "^2.2.14",
"shelljs": "^0.3.0"
},
"cordovaPlugins": [
"cordova-plugin-device",
"cordova-plugin-console",
"cordova-plugin-whitelist",
"cordova-plugin-splashscreen",
"com.ionic.keyboard"
],
"cordovaPlatforms": [
"android"
]
}
I think it might be dependeny problem with the angular-resource but I can’t figure-out.Can anyone help me please.