Created
March 12, 2015 05:31
-
-
Save Jamp/bc253776b4dcb011010d to your computer and use it in GitHub Desktop.
Problema con Ionic/AngularJS y FirefoxOS
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var app = angular.module( 'myApp', [] ).config(['$compileProvider', function($compileProvider) { | |
$compileProvider.aHrefSanitizationWhitelist(/^\s*(https?|ftp|mailto|app):/); | |
$compileProvider.imgSrcSanitizationWhitelist(/^\s*(https?|ftp|mailto|app):/); | |
} | |
]); | |
Ejemplo: | |
// Ionic Starter App | |
angular.module('starter', ['ionic', 'starter.controllers', 'starter.directive', 'starter.factory']) | |
.run(function($ionicPlatform) { | |
$ionicPlatform.ready(function() { | |
if (window.cordova && window.cordova.plugins.Keyboard) { | |
cordova.plugins.Keyboard.hideKeyboardAccessoryBar(true); | |
} | |
if (window.StatusBar) { | |
StatusBar.styleDefault(); | |
} | |
}); | |
}) | |
///////////////////////////////////////// | |
.config(['$compileProvider', function($compileProvider) { | |
// Resolución de problemas al trabajar con FirefoxOS | |
$compileProvider.aHrefSanitizationWhitelist(/^\s*(https?|ftp|mailto|app):/); | |
$compileProvider.imgSrcSanitizationWhitelist(/^\s*(https?|ftp|mailto|app):/); | |
} | |
]) | |
///////////////////////////////////////// | |
.config(function($stateProvider, $urlRouterProvider) { | |
$stateProvider | |
.state('app', { | |
url: "/app", | |
abstract: true, | |
templateUrl: "templates/menu.html", | |
controller: 'AppCtrl' | |
}) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var app = angular.module( 'myApp', [] ).config(['$compileProvider', function($compileProvider) { | |
$compileProvider.urlSanitizationWhitelist(/^\s*(https?|ftp|mailto|app):/); | |
} | |
]); | |
Ejemplo: | |
// Ionic Starter App | |
angular.module('starter', ['ionic', 'starter.controllers', 'starter.directive', 'starter.factory']) | |
.run(function($ionicPlatform) { | |
$ionicPlatform.ready(function() { | |
if (window.cordova && window.cordova.plugins.Keyboard) { | |
cordova.plugins.Keyboard.hideKeyboardAccessoryBar(true); | |
} | |
if (window.StatusBar) { | |
StatusBar.styleDefault(); | |
} | |
}); | |
}) | |
///////////////////////////////////////// | |
.config(['$compileProvider', function($compileProvider) { | |
$compileProvider.urlSanitizationWhitelist(/^\s*(https?|ftp|mailto|app):/); | |
} | |
]) | |
///////////////////////////////////////// | |
.config(function($stateProvider, $urlRouterProvider) { | |
$stateProvider | |
.state('app', { | |
url: "/app", | |
abstract: true, | |
templateUrl: "templates/menu.html", | |
controller: 'AppCtrl' | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment