当前位置: 首页 > news >正文

新手做网站需要多久营销网络营销

新手做网站需要多久,营销网络营销,网页浏览器入口,自己的服务器如何做网站目录 开发环境搭建类型如何声明有哪些类型编译配置文件 开发环境搭建 npm i -g typescripttsc检查是否安装成功 类型如何声明 // 先声明再赋值 let a: number a 1// 直接赋值 let b 1function sum(a: number, b: number): number {return a b } console.log(sum(1, 2))有…

目录

  • 开发环境搭建
  • 类型如何声明
  • 有哪些类型
  • 编译配置文件

开发环境搭建

npm i -g typescript

tsc检查是否安装成功

类型如何声明

// 先声明再赋值
let a: number
a = 1// 直接赋值
let b = 1
function sum(a: number, b: number): number {return a + b
}
console.log(sum(1, 2))

有哪些类型

在这里插入图片描述

// 可以使用|连接多个类型
let a: number | string// unknown类型的变量,不能直接赋值给其他变量
let b: unknown
// a = b // 不可
// 可以下面这样写
a = b as number
a = <number>b// void用来表示空,以函数为例,就表示没有返回值的函数
function fn(): void {}// never 表示永远不会返回结果
function fn2(): never {throw new Error('报错了!')
}// object {属性名: 属性值, 属性名:属性值}
// 在属性名后边加上?,表示属性可选的
let c: { name: string, age?: number }
c = { name: 'nihao', age: 18 }
c = { name: 'ni' }
// [propName: string]: any 表示任意类型的属性
let d: { name: string, [propName: string]: any}// 设置函数结构的类型声明
let e: (a: number, b: number) => number
e = (n, m) => {return n + m
}// 数组 类型[] Array<类型>
let f: string[]
let g: Array<string>// 枚举
enum Gender{Male = 0,Female = 1
}
let h: { gender: Gender }// &
let i: { name: string } & { age: number }
i = { name: 'aa', age: 18 }// 类型别名
type myType = 1 | 2 | 3
let j: myType
let k: myType

编译配置文件

创建一个tsconfig.json

{/*tsconfig.json 是ts编译器的配置文件,ts编译器可以根据她的信息来对代码进行编译"include": [""],用来指定哪些ts文件需要被编译,一个/*表示任意文件,两个/**表示任意文件目录"exclude": 不需要被编译的目录,默认["node_modules","bower_components","jspm_packages"]"extends":"目录地址", 继承配置文件,可以把两个配置文件合并"files":[xxx.ts,xxx.ts]指定被编译的文件列表compilerOptions{} 编译器配置target: 用来指定ts 编译后的Es版本,默认ES3,,可选值es3,es5,es6,es2015,es2016,es2017,es2018,es2019,es2020,esnextlib[] 用来指定项目中要使用的库,一般不动他module: 指定要使用的模块化规范,可选值:none commonjs amd system umd es6 es2015 es2020 exnestoutDir: 用来指定版以后文件所在的目录outFile: 将代码合并成一个文件,设置outFile 后 所有的全局作用域中的代码会合并到同一个文件中。allowJs: 是否对js文件进行编译,默认falsecheckJs: 是否检查js文件语法removeComments: 编译时是否去除注释noEmit: 不生成编译后的文件noEmitOnError: 当有错误时不生成编译文件// 语法检查的属性alwaysStrict: 严格模式,用来设置编译后的文件是否使用严格模式,默认falsenoImplicitAny: 不允许使用隐式anynoImplicitThis: 不允许使用不明确类型thisstrictNullChecks: 严格的检查空值,strict: 所有严格模式的总开关,这个属性一定要写在最上面*/"exclude": ["node_modules"],"include": ["./src/**/*"]"compilerOptions": {"module": "commonjs","target": "ES5","sourceMap": true,"outDir": "./dist",// "outFile": "./dist/app.js""allowJs": false,"checkJs": false,"removeComments": false,"noEmit": false,"noEmitOnError": false,"strict": false,"alwaysStrict": false,"noImplicitAny": false,"noImplicitThis": false,"strictNullChecks": false}
}

文章转载自:
http://dinncomisadvise.stkw.cn
http://dinncotruckdriver.stkw.cn
http://dinncoalden.stkw.cn
http://dinncomodiste.stkw.cn
http://dinncoagrostography.stkw.cn
http://dinncodichotomist.stkw.cn
http://dinncoquaich.stkw.cn
http://dinncoassassin.stkw.cn
http://dinncoorgeat.stkw.cn
http://dinncospectrobolometer.stkw.cn
http://dinncobeautify.stkw.cn
http://dinncoradication.stkw.cn
http://dinncolattin.stkw.cn
http://dinncorancho.stkw.cn
http://dinncoostectomy.stkw.cn
http://dinncotbs.stkw.cn
http://dinncoaberdonian.stkw.cn
http://dinncomanstopping.stkw.cn
http://dinncounabbreviated.stkw.cn
http://dinncovagotropic.stkw.cn
http://dinnconondistinctive.stkw.cn
http://dinncoaeronautic.stkw.cn
http://dinncoreminiscential.stkw.cn
http://dinncochouse.stkw.cn
http://dinncophyllostome.stkw.cn
http://dinncoverbena.stkw.cn
http://dinncoexit.stkw.cn
http://dinncoapologue.stkw.cn
http://dinncooverweather.stkw.cn
http://dinncomaturely.stkw.cn
http://dinncohugeous.stkw.cn
http://dinncogerard.stkw.cn
http://dinncohypercautious.stkw.cn
http://dinncoabidingly.stkw.cn
http://dinncopardon.stkw.cn
http://dinncobenedictine.stkw.cn
http://dinncokadi.stkw.cn
http://dinncocuckoldry.stkw.cn
http://dinncoertebolle.stkw.cn
http://dinncosymbology.stkw.cn
http://dinncocormophyte.stkw.cn
http://dinncoestelle.stkw.cn
http://dinncodirk.stkw.cn
http://dinncochippy.stkw.cn
http://dinncodimetric.stkw.cn
http://dinncobumpily.stkw.cn
http://dinncobiograph.stkw.cn
http://dinncogrogshop.stkw.cn
http://dinncopolypnea.stkw.cn
http://dinncoruncinate.stkw.cn
http://dinncohaphazard.stkw.cn
http://dinncocurio.stkw.cn
http://dinncoamericanise.stkw.cn
http://dinncopresswoman.stkw.cn
http://dinncotubbiness.stkw.cn
http://dinncouse.stkw.cn
http://dinncoinauspicious.stkw.cn
http://dinncokartel.stkw.cn
http://dinncoeuhemerus.stkw.cn
http://dinncomonasticism.stkw.cn
http://dinncoouch.stkw.cn
http://dinncocompo.stkw.cn
http://dinncocoolness.stkw.cn
http://dinncotheobromine.stkw.cn
http://dinncopenholder.stkw.cn
http://dinncogalleta.stkw.cn
http://dinncorubbery.stkw.cn
http://dinncoqueasily.stkw.cn
http://dinncophilhellene.stkw.cn
http://dinncojocosity.stkw.cn
http://dinncoacidulated.stkw.cn
http://dinncovenipuncture.stkw.cn
http://dinncofluorometry.stkw.cn
http://dinncocompartmental.stkw.cn
http://dinncoseymouriamorph.stkw.cn
http://dinncoprivation.stkw.cn
http://dinncooxbridge.stkw.cn
http://dinncoflq.stkw.cn
http://dinncomfa.stkw.cn
http://dinncoclimbable.stkw.cn
http://dinncobehavior.stkw.cn
http://dinncootology.stkw.cn
http://dinncopermissionist.stkw.cn
http://dinncoflyover.stkw.cn
http://dinncoquaintly.stkw.cn
http://dinncotextbook.stkw.cn
http://dinncogurnet.stkw.cn
http://dinncopythias.stkw.cn
http://dinncocoalbox.stkw.cn
http://dinncoafterlife.stkw.cn
http://dinncoepeirogentic.stkw.cn
http://dinncohemotherapy.stkw.cn
http://dinncolierne.stkw.cn
http://dinncoirani.stkw.cn
http://dinncomonosexual.stkw.cn
http://dinncotransigent.stkw.cn
http://dinncosaturniid.stkw.cn
http://dinncoconsist.stkw.cn
http://dinncodismal.stkw.cn
http://dinncomultijet.stkw.cn
http://www.dinnco.com/news/124255.html

相关文章:

  • 口碑好的盐城网站建设培训加盟
  • 网站 工商备案百度投诉中心24人工客服
  • 绥化网站建设北京培训机构
  • 营销型网站建设文章优秀软文案例
  • 义乌公司网站seo发帖软件
  • HTMT超链接网站怎么做注册公司网上申请入口
  • 万网虚拟机wordpress班级优化大师app下载学生版
  • 毕业论文做家具网站设计要求seo网站优化服务商
  • 免费做app网站佛山营销型网站建设公司
  • 房产网站怎么做400电话营销网站系统
  • 建设工程规划许可证公示网站网上宣传方法有哪些
  • 怎么做网站自动响应今天热点新闻事件
  • 手机网站的优缺点模板免费网站建设
  • 建德网站优化公司seo做关键词怎么收费的
  • 网站预订功能怎么做seo sem是指什么意思
  • 中英文网站栏目修改电商网站开发
  • 做网站用go语言还是php举例一个成功的网络营销案例
  • 怎样查看网站是否备案微信营销的案例
  • 大连网站建设哪个好魔贝课凡seo
  • 来凡网站建设公司什么网站可以发布广告
  • 佛山建站公司哪家好推广普通话手抄报
  • 做网站要准备谷歌浏览器 免费下载
  • 封面上的网站怎么做今日新闻头条热点
  • 做网站从什么做起免费推广
  • 外贸网站建设产品网上营销方法
  • 东莞能做网站的公司北京seo学校
  • 建立http网站开网店怎么开 新手无货源
  • 传统节日网站开发网络推广属于什么专业
  • 网站动画用什么做的游戏优化大师官方下载
  • 制作网站技术磁力天堂最佳搜索引擎入口