Angular-集成-Typescript-版本-Echarts-(附代码),flutter二维码扫描插件

],
imports: [
BrowserModule,
AppRoutingModule,
NgxEchartsModule
],
providers: [],
bootstrap: [AppComponent]
})
export class AppModule { }

在 html 中添加:

angular works!

有需要的话也可以使用 [initOpts] 等 API,这些会在后面介绍

然后写一个被广泛流传的 echarts-typescript 例子:

import { Component } from ‘@angular/core’;
import { EChartOption } from ‘echarts’

@Component({
selector: ‘app-root’,
templateUrl: ‘./app.component.html’,
styleUrls: [’./app.component.css’]
})
export class AppComponent {
title = ‘angular-echarts-example’;

chartOption: EChartOption = {
tooltip: {
trigger: ‘axis’,
axisPointer: {
type: ‘cross’,
crossStyle: {
color: ‘#999’
}
}
},
toolbox: {
feature: {
dataView: {
show: true,
readOnly: false,
title: ‘Datensicht’
},
magicType: {
show: true,
type: [‘line’, ‘bar’],
title: ‘migic type’
},
restore: {
show: true,
title: ‘Zurücksetzen’
},
saveAsImage: {
show: true,
title: ‘Speichern’
}
}
},
legend: {
data: [‘蒸发量’, ‘降水量’, ‘平均温度’]
},
xAxis: [
{
type: ‘category’,
data: [‘1月’, ‘2月’, ‘3月’, ‘4月’, ‘5月’, ‘6月’, ‘7月’, ‘8月’, ‘9月’, ‘10月’, ‘11月’, ‘12月’],
axisPointer: {
type: ‘shadow’
}
}
],
yAxis: [
{
type: ‘value’,
name: ‘水量’,
min: 0,
max: 250,
interval: 50,
axisLabel: {
formatter: ‘{value} ml’
}
},
{
type: ‘value’,
name: ‘温度’,
min: 0,
max: 25,
interval: 5,
axisLabel: {
formatter: ‘{value} °C’
}
}
],
series: [
{
name: ‘蒸发量’,
type: ‘bar’,
data: [2.0, 4.9, 7.0, 23.2, 25.6, 76.7, 135.6, 162.2, 32.6, 20.0, 6.4, 3.3]
},
{
name: ‘降水量’,
type: ‘bar’,
data: [2.6, 5.9, 9.0, 26.4, 28.7, 70.7, 175.6, 182.2, 48.7, 18.8, 6.0, 2.3]
},
{
name: ‘平均温度’,
type: ‘line’,
yAxisIndex: 1,
data: [2.0, 2.2, 3.3, 4.5, 6.3, 10.2, 20.3, 23.4, 23.0, 16.5, 12.0, 6.2]
}
]
}
}

储存并启动 Angular 程序:

$ ng serve --open

会看到如下页面,并且可以用鼠标与其进行交互式操作

[图片上传失败…(image-ef8f6e-1595846992017)]

Angular-集成-Typescript-版本-Echarts-(附代码),flutter二维码扫描插件_第1张图片

最后

跳槽季整理面试题已经成了我多年的习惯!在这里我和身边一些朋友特意整理了一份快速进阶为Android高级工程师的系统且全面的学习资料。涵盖了Android初级——Android高级架构师进阶必备的一些学习技能。

附上:我们之前因为秋招收集的二十套一二线互联网公司Android面试真题(含BAT、小米、华为、美团、滴滴)和我自己整理Android复习笔记(包含Android基础知识点、Android扩展知识点、Android源码解析、设计模式汇总、Gradle知识点、常见算法题汇总。)

Angular-集成-Typescript-版本-Echarts-(附代码),flutter二维码扫描插件_第2张图片

本文在开源项目:【GitHub 】中已收录,里面包含不同方向的自学编程路线、面试题集合/面经、及系列技术文章等,资源持续更新中…
%99%E4%BA%9B%EF%BC%9F%E5%A6%82%E4%BD%95%E9%9D%A2%E8%AF%95%E6%8B%BF%E9%AB%98%E8%96%AA%EF%BC%81.md) 】中已收录,里面包含不同方向的自学编程路线、面试题集合/面经、及系列技术文章等,资源持续更新中…**

你可能感兴趣的:(程序员,面试,移动开发,android)