我写作TypeScript和HTML文件,标签变成了空格.这是我第一次使用Visual Studio Code.
我试图更改设置并重新启动,但没有任何改变.
我配置的设置:
{
"editor.insertSpaces": false
}
Run Code Online (Sandbox Code Playgroud)
我想谷歌它,我发现我做了正确的一步,当我加入TypeScript到.html,但它不改变我的喜好...
编辑1:
我发现标签工作在.ts文件中,但不是TypeScript文件...
我正在使用Angularjs.
我有一串数字,例如:610.这意味着秒.我需要它改为:10:10或者610.
我需要几秒钟的时间过滤.我该怎么做?
谢谢.
我正在使用Firebase,Backend-as-a-Service,用于我的网站应用程序,由AngularJS编程.
我想使用db查询来获取记录,例如: WHERE name == 'The Legend Of Korra'
我在Firebase服务器中有一系列电视剧,JSON代码:
{
"series" : {
"-JkqSvwyDw5F9DvGUu6b" : {
"createdAt" : 1426842959884,
"creators" : "Michael Dante DiMartino,Bryan Konietzko",
"description" : "The series follows the adventures of protagonist twelve-year-old Aang and his friends, who must bring peace and unity to the world by ending the Fire Lord's war against the other three nations.",
"episode_reset" : true,
"genres" : "Action,Adventure,Fantasy,Comedy-drama",
"keywords" : "avatar,the last airbender",
"name" : "Avatar: The Last Airbender",
"official_website" …Run Code Online (Sandbox Code Playgroud) 我正在尝试更改范围变量:$scope.tab每次窗口调整大小时$scope.tab == 'more'.
码:
$scope.closeMoreTab = function() {
if($scope.tab == 'more')
$scope.tab = 'extras';
};
angular.element($window).bind('resize', function() {
$scope.closeMoreTab();
});
Run Code Online (Sandbox Code Playgroud)
好吧,它确实在调用$scope.closeMoreTab(),而且它确实在改变$scope.tab变量,但实际上,它并没有改变视图上的任何内容.
我试过了:
console.log($scope);
Run Code Online (Sandbox Code Playgroud)
要检查变量tab,它确实变为'extras',但是当我这样做时:
<div>{{ tab }}</div>
Run Code Online (Sandbox Code Playgroud)
它告诉我,当前的tab变量仍然是"更多"
请帮忙.我坚持了1个小时,不知道为什么会这样或者做什么.
非常感谢
angularjs ×3
angularfire ×1
date ×1
firebase ×1
javascript ×1
scope ×1
spaces ×1
tabs ×1
time ×1
typescript ×1