Durandal / Knockout - global observable
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: Context In my shell.html I have put a language selection into the header section. It looks like this: <select class="form-control select2" data-bind="options:languages, optionsText:'label', optionsValue:'code', value:selectedLanguage"> </select> My shell.js: When I load other views, this always stays in the header and does not change. Task Whenever the user changes the language, I want to be able to register/notice this on any sub-page and then react accordingly - like showing the text in another language. Question I suppose this is more of