Flowing
Dev
更多工具
添加到项目
项目模式
搜索工具和命令…
⌘ K
简体中文
Angular Playground
免费
在浏览器中实时尝试 Angular 独立组件、信号和模板。 你的代码在浏览器里独立的沙盒中运行,绝不会被上传。
基础知识
main.ts
style.css
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
import "@angular/compiler"; import { Component, signal, provideExperimentalZonelessChangeDetection } from "@angular/core"; import { bootstrapApplication } from "@angular/platform-browser"; @Component({ selector: "app-root", standalone: true, template: ` <h1>Angular playground 🅰️</h1> <button (click)="inc()">Count: {{ count() }}</button> `, }) class App { count = signal(0); inc() { this.count.update((c) => c + 1); console.log("count", this.count()); } } bootstrapApplication(App, { providers: [provideExperimentalZonelessChangeDetection()] });
运行
按 Ctrl/⌘ + Enter 运行
运行时: Angular 19 (JIT) + TypeScript
控制台
点击“运行”来执行你的代码。