首页 > 代码库 > 神秘的语言选项
神秘的语言选项
刚开始旁边的同事一直说是在线编译导致速度慢,后来看到提示有https://github.com/shootaroo/jit-grunt#static-mappings
进去看了说明再检查工程里面是有配置的, 所以不是这个问题.
require(‘jit-grunt‘)(grunt);
然而的怎么改本地数据都没用, 一定是从网上在线请求了欧洲版的数据.
查看Network, 里面vendor.js的请求最多, sources搜language打断点停在这:
function $translate($STORAGE_KEY, $windowProvider, $translateSanitizationProvider,
pascalprechtTranslateOverrider) { "use strict"; var $preferredLanguage, $languageKeyAliases, $fallbackLanguage,
$fallbackWasString, $uses, $nextLang, $storageFactory, $storagePrefix,
$missingTranslationHandlerFactory, $interpolationFactory, $loaderFactory,
$loaderOptions, $notFoundIndicatorLeft, $notFoundIndicatorRight, loaderCache,
$translationTable = {}, $availableLanguageKeys = [], $storageKey = $STORAGE_KEY,
$interpolatorFactories = [], $cloakClassName = "translate-cloak",
$postCompilingEnabled = !1, $forceAsyncReloadEnabled = !1,
$nestedObjectDelimeter = ".", $isReady = !1, directivePriority = 0,
statefulFilter = !0, uniformLanguageTagResolver = "default", languageTagResolver = {
奶奶掉了这么个借口,这么多参数...
具体到页面html是index.html,login.html,language-switcher.html
Directive是showErrors
<ui-select showErrors data-api-validate id="language" name="language" data-ng-model="user.language" required
theme="bootstrap" ng-disabled="disabled" style="min-width: 300px;">
插件用法 : http://v7sky.iteye.com/blog/2304175
神秘的语言选项
声明:以上内容来自用户投稿及互联网公开渠道收集整理发布,本网站不拥有所有权,未作人工编辑处理,也不承担相关法律责任,若内容有误或涉及侵权可进行投诉: 投诉/举报 工作人员会在5个工作日内联系你,一经查实,本站将立刻删除涉嫌侵权内容。