├── .editorconfig
├── .eslintrc.js
├── .github
└── FUNDING.yml
├── .gitignore
├── .prettierrc.js
├── .vscode
└── settings.json
├── CODE-OF-CONDUCT.md
├── LICENSE
├── README.md
├── media
└── tscurso.gif
├── modulo-01
├── README.md
└── helloworld
│ ├── app.js
│ └── app.ts
├── modulo-02
├── 08-aula-type-annotation
│ ├── typeAnnotation.js
│ └── typeAnnotation.ts
├── 10-aula-tipo-boolean
│ ├── booleanType.js
│ └── booleanType.ts
├── 12-aula-number-bigint
│ ├── numberBigint.js
│ └── numberBigint.ts
├── 14-aula-tipo-string
│ ├── stringType.js
│ └── stringType.ts
├── 16-aula-tipo-array
│ ├── arrayType.js
│ └── arrayType.ts
├── 18-aula-tipo-tuple
│ ├── tupleType.js
│ └── tupleType.ts
├── 20-aula-tipo-enum
│ └── enumType.ts
├── 22-aula-tipo-any
│ └── anyType.ts
├── 24-aula-tipo-unknown
│ └── unknownType.ts
├── 26-aula-tipo-void
│ └── voidType.ts
├── 28-aula-null-undefined
│ └── nullUndefinedType.ts
├── 30-aula-tipo-never
│ └── neverType.ts
├── 32-aula-tipo-object
│ └── objectType.ts
└── README.md
├── modulo-03
├── README.md
├── aula-35-if-else
│ └── if-else.ts
├── aula-37-switch-case
│ └── switch-case.ts
├── aula-39-loop-for
│ └── loop-for.ts
└── aula-41-loop-while
│ └── loop-while.ts
├── modulo-04
├── README.md
├── aula-43-functions
│ └── functions.ts
├── aula-45-optional-parameters
│ └── optionalParameters.ts
├── aula-47-default-parameters
│ └── defaultParameters.ts
└── aula-49-rest-parameters
│ └── restParameters.ts
├── modulo-05
├── README.md
├── aula-51-classes
│ └── classes.ts
├── aula-53-access-modifier
│ └── accessModifier.ts
├── aula-55-access-modifier-readonly
│ └── readonlyModifier.ts
├── aula-57-getters-setters
│ └── gettersSetters.ts
├── aula-59-inheritance
│ └── inheritance.ts
├── aula-61-static-members
│ └── static.ts
└── aula-63-abstract-classes
│ └── abstractClasses.ts
├── modulo-06
├── README.md
├── aula-65-interfaces
│ └── interfaces.ts
└── aula-67-extends-interfaces
│ └── extendsInterfaces.ts
├── modulo-07
├── README.md
├── aula-69-intersection-types
│ └── intersectionTypes.ts
├── aula-71-type-guards
│ └── typeGuards.ts
├── aula-73-type-casting
│ └── typeCasting.ts
├── aula-75-type-assertion
│ └── typeAssertions.ts
├── aula-77-conditional-types
│ └── conditionalTypes.ts
├── aula-79-mapped-types
│ └── mappedTypes.ts
└── aula-81-satisfies-operator
│ └── satisfiesOperator.ts
├── modulo-08
├── README.md
├── aula-83-intro-generics
│ └── generics.ts
├── aula-85-generics-contraints
│ └── genericsConstraints.ts
├── aula-87-generic-classes
│ └── genericClasses.ts
└── aula-89-generics-interfaces
│ └── genericsInterfaces.ts
├── modulo-09
├── README.md
├── aula-91-intro-modules
│ ├── main.ts
│ └── math.ts
└── aula-911-modules
│ ├── main.ts
│ └── validators
│ ├── email-validator.ts
│ ├── index.ts
│ ├── validator.ts
│ └── zipcode-validator.ts
├── modulo-10
├── README.md
└── ts-node-express
│ ├── .gitignore
│ ├── package-lock.json
│ ├── package.json
│ ├── src
│ └── index.ts
│ └── tsconfig.json
├── package-lock.json
├── package.json
└── tsconfig.json
/.editorconfig:
--------------------------------------------------------------------------------
1 | # EditorConfig is awesome: https://EditorConfig.org
2 |
3 | # top-most EditorConfig file
4 | root = true
5 |
6 | [*]
7 | indent_style = space
8 | indent_size = 2
9 | end_of_line = auto
10 | charset = utf-8
11 | trim_trailing_whitespace = true
12 | insert_final_newline = true
13 |
--------------------------------------------------------------------------------
/.eslintrc.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | env: {
3 | browser: true,
4 | es6: true,
5 | node: true,
6 | },
7 | extends: [
8 | 'eslint:recommended',
9 | 'plugin:@typescript-eslint/eslint-recommended',
10 | 'plugin:@typescript-eslint/recommended',
11 | 'plugin:prettier/recommended',
12 | ],
13 | globals: {
14 | Atomics: 'readonly',
15 | SharedArrayBuffer: 'readonly',
16 | },
17 | parser: '@typescript-eslint/parser',
18 | parserOptions: {
19 | ecmaVersion: 11,
20 | sourceType: 'module',
21 | },
22 | plugins: ['@typescript-eslint'],
23 | rules: {
24 | '@typescript-eslint/no-empty-function': 'off',
25 | 'prettier/prettier': ['off', { singleQuote: true }],
26 | },
27 | };
28 |
--------------------------------------------------------------------------------
/.github/FUNDING.yml:
--------------------------------------------------------------------------------
1 | # These are supported funding model platforms
2 |
3 | github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
4 | patreon: # Replace with a single Patreon username
5 | open_collective: # Replace with a single Open Collective username
6 | ko_fi: glaucialemos
7 | tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
8 | community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
9 | liberapay: # Replace with a single Liberapay username
10 | issuehunt: # Replace with a single IssueHunt username
11 | otechie: # Replace with a single Otechie username
12 | custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
13 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | /node_modules
2 | dist
3 |
--------------------------------------------------------------------------------
/.prettierrc.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | semi: true,
3 | trailingComma: "all",
4 | singleQuote: true,
5 | printWidth: 80,
6 | tabWidth: 2,
7 | };
8 |
--------------------------------------------------------------------------------
/.vscode/settings.json:
--------------------------------------------------------------------------------
1 | {
2 | "cSpell.enableFiletypes": [
3 | "!typescript"
4 | ]
5 | }
--------------------------------------------------------------------------------
/CODE-OF-CONDUCT.md:
--------------------------------------------------------------------------------
1 | # Código de Conduta
2 |
3 | ## Nossa promessa
4 |
5 | Com o interesse de fomentar uma comunidade aberta e acolhedora,
6 | nós, como colaboradores e administradores deste projeto, comprometemo-nos
7 | a fazer a participação deste projeto uma experiência livre de assédio
8 | para todos, independentemente da aparência pessoal, deficiência,
9 | etnia, gênero, idade, identidade ou expressão de gênero, identidade
10 | ou orientação sexual, nacionalidade, nível de experiência, porte físico,
11 | raça ou religião.
12 |
13 | ## Nossos padrões
14 |
15 | Exemplos de comportamentos que contribuem a criar um ambiente positivo incluem:
16 |
17 | * Usar linguagem acolhedora e inclusiva
18 | * Respeitar pontos de vista e experiências diferentes
19 | * Aceitar crítica construtiva com graça
20 | * Focar no que é melhor para a comunidade
21 | * Mostrar empatia com outros membros da comunidade
22 |
23 | Exemplos de comportamentos inaceitáveis por parte dos participantes incluem:
24 |
25 | * Uso de linguagem ou imagens sexuais e atenção ou avanço sexual indesejada
26 | * Comentários insultuosos e/ou depreciativos e ataques pessoais ou políticos (*Trolling*)
27 | * Assédio público ou privado
28 | * Publicar informação pessoal de outros sem permissão explícita, como, por exemplo, um endereço eletrônico ou residencial
29 | * Qualquer outra forma de conduta que pode ser razoavelmente considerada inapropriada num ambiente profissional
30 |
31 | ## Nossas responsibilidades
32 |
33 | Os administradores do projeto são responsáveis por esclarecer os padrões de
34 | comportamento e deverão tomar ação corretiva apropriada e justa em resposta
35 | a qualquer instância de comportamento inaceitável.
36 |
37 | Os administradores do projeto têm o direito e a responsabilidade de
38 | remover, editar ou rejeitar comentários, commits, código, edições
39 | na wiki, erros ou outras formas de contribuição que não estejam de
40 | acordo com este Código de Conduta, bem como banir temporariamente ou
41 | permanentemente qualquer colaborador por qualquer outro comportamento
42 | que se considere impróprio, perigoso, ofensivo ou problemático.
43 |
44 | ## Escopo
45 |
46 | Este Código de Conduta aplica-se dentro dos espaços do projeto ou
47 | qualquer espaço público onde alguém represente o mesmo ou a sua
48 | comunidade. Exemplos de representação do projeto ou comunidade incluem
49 | usar um endereço de email oficial do projeto, postar por uma conta de
50 | mídia social oficial, ou agir como um representante designado num evento
51 | online ou offline. A representação de um projeto pode ser ainda definida e
52 | esclarecida pelos administradores do projeto.
53 |
54 | ## Aplicação
55 |
56 | Comportamento abusivo, de assédio ou de outros tipos pode ser
57 | comunicado contatando a equipe do projeto **[AQUI](gllemos@microsoft.com)**. Todas as queixas serão revistas e investigadas e
58 | resultarão numa resposta necessária e apropriada à situação.
59 | A equipe é obrigada a manter a confidencialidade em relação
60 | ao elemento que reportou o incidente. Demais detalhes de
61 | políticas de aplicação podem ser postadas separadamente.
62 |
63 | Administradores do projeto que não sigam ou não mantenham o Código
64 | de Conduta em boa fé podem enfrentar repercussões temporárias ou permanentes
65 | determinadas por outros membros da liderança do projeto.
66 |
67 | ## Atribuição
68 |
69 | Este Código de Conduta é adaptado do **[Contributor Covenant](https://www.contributor-covenant.org)**, versão 1.4, disponível em https://www.contributor-covenant.org/pt-br/version/1/4/code-of-conduct.html
70 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) 2021 Glaucia Lemos
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # Curso TypeScript - Zero to Hero
2 |
3 |
4 |
5 |
6 |
7 | Repositório responsável pelo Curso de TypeScript - Zero to Hero!
8 |
9 | Todo o treinamento foi elaborado pela Comunidade para a Comunidade! Assim sendo, distribuindo o conhecimento de maneira totalmente gratuita à todas as Pessoas Desenvolvedoras.
10 |
11 | Toda a emenda do treinamento, foi baseada na **[Documentação oficial do TypeScript](https://www.typescriptlang.org/docs/handbook/intro.html)**! Pois, não existe melhor lugar para estudar e entender uma determinada stack ou linguagem com ajuda da documentação oficial!
12 |
13 | ## 📌 Pré-Requisitos
14 |
15 | Para a realização desse curso, se faz necessário já possuir conhecimento prévio em JavaScript e Node.Js
16 |
17 | Caso não tenha, estamos disponibilizando abaixo, alguns treinamentos prévios, antes de começar a estudar o Curso de TypeScript - Zero to Hero
18 |
19 | - ✅ **[Curso Grátis TypeScript - Microsoft Learn](https://docs.microsoft.com/learn/paths/build-javascript-applications-typescript/?WT.mc_id=javascript-23355-gllemos)**
20 | - ✅ **[Curso Grátis JavaScript - Para Iniciantes](https://github.com/glaucia86/js-101-beginners-ms)**
21 | - ✅ **[Curso Grátis Node.Js - Microsoft Learn](https://docs.microsoft.com/learn/paths/build-javascript-applications-nodejs/?WT.mc_id=javascript-14034-gllemos)**
22 | - ✅ **[Curso Grátis Node.Js [Vídeo]](https://channel9.msdn.com/Series/Beginners-Series-to-NodeJS?WT.mc_id=javascript-14034-gllemos)**
23 |
24 | ## 🏃 Colaboradores
25 |
26 | Nesse projeto que estamos desenvolvendo para toda a Comunidade Técnica Brasileira, está sendo desenvolvida por:
27 |
28 | - **[Glaucia Lemos](https://twitter.com/glaucia_lemos86)**
29 |
30 | Porém, qualquer pessoa da Comunidade que deseja fazer parte desse projeto, nos auxiliando de alguma forma, entre em contato conosco, via DM's das nossas contas do Twitter: **[AQUI](https://twitter.com/glaucia_lemos86)**, que será um prazer em ter todos(as) vocês! Pois, acreditamos que, a união de toda a Comunidade é fundamental no compartilhamento de conhecimento!
31 |
32 | ## 🚀 Recursos Utilizados
33 |
34 | - **[TypeScript](https://www.typescriptlang.org/download)**
35 | - **[Visual Studio Code](https://code.visualstudio.com/?WT.mc_id=javascript-14034-gllemos)**
36 | - **[Node.js](https://nodejs.org/en/)**
37 | - **[Postman](https://www.getpostman.com/)**
38 | - **[Extensão Visual Studio Code - Code Runner](https://marketplace.visualstudio.com/items?itemName=formulahendry.code-runner&WT.mc_id=javascript-14034-gllemos)**
39 | - **[Extensão Visual Studio Code - Azure Functions](https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-azurefunctions&WT.mc_id=javascript-14034-gllemos)**
40 |
41 | ## 💻 Série de Vídeos
42 |
43 | Os vídeos serão lançados semanalmente, de acordo com a demanda através do meu **[Canal do Youtube](https://bit.ly/youtube-canal-glaucialemos)**.
44 |
45 | ## Quando será o Lançamento desse Curso?
46 |
47 | O lançamento dos primeiros vídeos sairão no dia 01/03/2021!
48 | E semanalmente estaremos lançando os vídeos aos poucos. Uma vez que o conteúdo é extremamente condensado e existe toda a questão de gravação e edição.
49 | Nesse ponto, pedirei paciência a todas as pessoas. Mas, estarei divulgando novos vídeos semanalmente!
50 |
51 | ## ✏️ Ementa do Curso
52 |
53 | Módulo 1: Introdução à TypeScript
54 |
55 | - 1.1 - O que é TypeScript?
56 | - 1.2 - Conhecendo o Playground do TypeScript
57 | - 1.3 - Preparando o Ambiente de Desenvolvimento para o TypeScript
58 | - 1.4 - Entendendo um pouco mais o arquivo tsconfig.json
59 | - 1.5 - Demo: Primeiro Programa em TypeScript – Hello World
60 | - 1.6 - E por que usar o TypeScript? E, próximos passos!
61 |
62 |
63 | Módulo 2: Tipos Básicos
64 |
65 | - 2.1 - Type Annotation
66 | - Demo 2.1
67 | - 2.2 - Boolean
68 | - Demo 2.2
69 | - 2.3 - Number & Bigint
70 | - Demo 2.3
71 | - 2.4 - String
72 | - Demo 2.4
73 | - 2.5 - Array
74 | - Demo 2.5
75 | - 2.6 - Tuple
76 | - Demo 2.6
77 | - 2.7 - Enum
78 | - Demo 2.7
79 | - 2.8 - Unknown
80 | - Demo 2.8
81 | - 2.9 - Any
82 | - Demo 2.9
83 | - 2.10 - Void
84 | - Demo 2.10
85 | - 2.11 - Null and Undefined
86 | - Demo 2.11
87 | - 2.12 - Never
88 | - Demo 2.12
89 | - 2.13 - Object
90 | - Demo 2.13
91 |
92 |
93 | Módulo 3: Fluxos de Controle
94 |
95 | - 3.1 - Condicional if...else
96 | - Demo 3.1
97 | - 3.2 - Condicional switch... case
98 | - Demo 3.2
99 | - 3.3 - Condicional for
100 | - Demo 3.3
101 | - 3.4 - Condicional while
102 | - Demo 3.4
103 |
104 |
105 | Módulo 4: Funções/Functions
106 |
107 | - 4.1 - Introdução à Funções/Functions
108 | - Demo 4.1
109 | - 4.2 - Optional Parameters
110 | - Demo 4.2
111 | - 4.3 - Default Parameters
112 | - Demo 4.3
113 | - 4.4 - Rest Parameters
114 | - Demo 4.4
115 | - 4.5 - Uso do ‘this’ e Arrow Functions
116 | - Demo 4.5
117 | - 4.6 - this Parameters
118 | - Demo 4.6
119 | - 4.7 - this Parameters em Callbacks
120 | - Demo 4.7
121 | - 4.8 - Function Overloadings
122 | - Demo 4.8
123 |
124 |
125 | Módulo 5: Classes
126 |
127 | - 5.1 - Introdução à Classes
128 | - Demo 5.1
129 | - 5.2 - Modificadores de Acesso em TypeScript
130 | - Demo 5.2
131 | - 5.3 - Modificadores readonly
132 | - Demo 5.3
133 | - 5.4 - Uso dos Getters & Setters
134 | - Demo 5.4
135 | - 5.5 - Herança
136 | - Demo 5.5
137 | - 5.6 - Métodos & Propriedades estáticas
138 | - Demo 5.6
139 | - 5.7 - Classes Abstratas
140 | - Demo 5.7
141 |
142 |
143 | Módulo 6: Interfaces
144 |
145 | - 6.1 - Introdução à Interfaces
146 | - 6.1.2 - Optional Properties
147 | - 6.1.3 - Propriedades Readonly
148 | - 6.1.4 - Function Types
149 | - 6.1.5 - Class Types
150 | - Demo 6.1
151 | - 6.2 - Extensão de Interfaces
152 | - 6.2.1 - Extensão de uma Interface
153 | - 6.2.2 - Extensão de Múltiplas Interfaces
154 | - 6.2.3 - Uso do Omit em Interfaces
155 | - Demo 6.2
156 |
157 |
158 | Módulo 7: Tipos Avançados & Novos Operadores
159 |
160 | - 7.1 - Intersection Types
161 | - Demo 7.1
162 | - 7.2 - Union Types
163 | - Demo 7.2
164 | - 7.3 - Type Guards
165 | - Demo 7.3
166 | - 7.4 - Type Casting
167 | - Demo 7.4
168 | - 7.5 - Type Assertions
169 | - Demo 7.5
170 | - 7.6 - Conditional Types
171 | - Demo 7.6
172 | - 7.7 - Mapped Types
173 | - Demo 7.7
174 | - 7.8 - Satisfies Operator
175 | - Demo 7.8
176 |
177 |
178 | Módulo 8: Generics
179 |
180 | - 8.1 - Introdução a Generics em TypeScript
181 | - Demo 8.1
182 | - 8.2 - Trabalhando com Tipos de Variáveis - Genéricas
183 | - Demo 8.2
184 | - 8.3 - Generic Types
185 | - Demo 8.3
186 | - 8.4 - Generic Classes
187 | - Demo 8.4
188 | - 8.5 - Generic Constraints
189 | - Demo 8.5
190 | - 8.6 - Generic Interfaces
191 | - Demo 8.6
192 |
193 |
194 | Módulo 9: Módulos
195 |
196 | - 9.1 - Introdução à Modules no Typescript (todos os tópicos abaixo já numa única aula)
197 | - 9.1.2 - Usando Function Modules
198 | - 9.1.3 - Default Exports
199 | - 9.1.4 - Class Modules
200 | - 9.1.5 - Usando aliases Class Modules em TypeScript
201 |
202 |
203 | Módulo 10: TypeScript em Node.js
204 |
205 | - 10.1 - Como podemos usar o Node.js com TypeScript + Express.Js
206 | - Demo 10.1
207 |
208 |
209 | Extras: Pós finalização do curso!
210 |
211 | - 11.1 -
212 |
213 |
214 | ## ❗️ Links & Recursos Importantes
215 |
216 | - ✅ **[Documentação Oficial do TypeScript](http://typescriptlang.org/docs/handbook/)**
217 | - ✅ **[TypeScript no Visual Studio Code](https://code.visualstudio.com/docs/languages/typescript?WT.mc_id=javascript-14034-gllemos)**
218 | - ✅ **[Compilando Códigos TypeScript no Vs Code](https://code.visualstudio.com/docs/typescript/typescript-compiling?WT.mc_id=javascript-14034-gllemos)**
219 | - ✅ **[Tutorial TypeScript no Vs Code](https://code.visualstudio.com/docs/typescript/typescript-tutorial?WT.mc_id=javascript-14034-gllemos)**
220 | - ✅ **[Azure Functions com TypeScript](https://docs.microsoft.com/azure/azure-functions/create-first-function-vs-code-typescript?WT.mc_id=javascript-14034-gllemos)**
221 | - ✅ **[Curso Grátis de Node.js](https://docs.microsoft.com/learn/paths/build-javascript-applications-nodejs/?WT.mc_id=javascript-14034-gllemos)**
222 |
223 | ## ❓ Tenho Dúvidas... O que Faço?!
224 |
225 | Caso tenham dúvidas aos códigos desenvolvidos durante a série de vídeos, sintam-se à vontade em abrir uma **[ISSUE AQUI](https://github.com/glaucia86/curso-typescript-zero-to-hero/issues)**. Assim que possível, estaremos respondendo a todas as dúvidas que tiverem!
226 |
--------------------------------------------------------------------------------
/media/tscurso.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glaucia86/curso-typescript-zero-to-hero/036074c6b61ad54e7fb2e488cb4565ebb18a9c54/media/tscurso.gif
--------------------------------------------------------------------------------
/modulo-01/README.md:
--------------------------------------------------------------------------------
1 | # Módulo 01: Introdução à TypeScript
2 |
3 | Aqui vocês encontrarão todos os vídeos e os exemplos desenvolvidos durante o módulo 01.
4 |
5 | ## 💻 Série de Vídeos
6 |
7 | | Vídeo Aula | Descrição |
8 | |---|---|
9 | | **[Vídeo 01](https://youtu.be/u7K1sdnCv5Y)** | Vídeo 01 - O que é TypeScript? |
10 | | **[Vídeo 02](https://youtu.be/_pDsn0gE6ys)** | Vídeo 02 - Conhecendo o Playground do TypeScript |
11 | | **[Vídeo 03](https://youtu.be/J-sMh3DF10U)** | Vídeo 03 - Preparando o Ambiente de Desenvolvimento para o TypeScript |
12 | | **[Vídeo 04](https://youtu.be/iYXzT08sX5Y)** | Vídeo 04 - Entendendo um pouco mais o arquivo tsconfig.json |
13 | | **[Vídeo 05](https://youtu.be/iTCRgdEyq0k)** | Vídeo 05 - Demo: Primeiro Programa em TypeScript – Hello World |
14 | | **[Vídeo 06](https://youtu.be/VIYnya9DUxg)** | Vídeo 06 - E por que usar o TypeScript? E, próximos passos! |
15 |
--------------------------------------------------------------------------------
/modulo-01/helloworld/app.js:
--------------------------------------------------------------------------------
1 | "use strict";
2 | /**
3 | * arquivo: helloworld/app.ts
4 | * descrição: arquivo responsável por ensinar conceitos básicos sobre TypeScript
5 | * data: 16/02/2021
6 | * author: Glaucia Lemos <@glaucia_lemos86>
7 | * Transpilação do arquivo: CTRL + SHIFT + B
8 | */
9 | let mensagem = 'Hello World, Glaucia Lemos!';
10 | console.log(mensagem);
11 |
--------------------------------------------------------------------------------
/modulo-01/helloworld/app.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: helloworld/app.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre TypeScript
4 | * data: 16/02/2021
5 | * author: Glaucia Lemos <@glaucia_lemos86>
6 | * Transpilação do arquivo: CTRL + SHIFT + B
7 | */
8 |
9 | let mensagem: string = 'Hello World, Glaucia Lemos!';
10 | console.log(mensagem);
--------------------------------------------------------------------------------
/modulo-02/08-aula-type-annotation/typeAnnotation.js:
--------------------------------------------------------------------------------
1 | "use strict";
2 | /**
3 | * arquivo: typeAnnotation.ts
4 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Type Annotation'
5 | * data: 16/02/2021
6 | * author: Glaucia Lemos <@glaucia_lemos86>
7 | * doc referência: https://www.typescriptlang.org/docs/handbook/2/everyday-types.html
8 | * Transpilação do arquivo: CTRL + SHIFT + B -> tsc: build/watch
9 | */
10 | // ==> Variáveis [Type Annotations]
11 | let nome = 'Glaucia Lemos';
12 | console.log(nome);
13 | // ==> Arrays [Type Annotations]
14 | let animais = ['Elefante', 'Cachorro', 'Gato', 'Panda', 'Girafa'];
15 | console.log(animais);
16 | // ==> Objetos [Type Annotations]
17 | let carro;
18 | carro = { nome: 'Toyota Yaris Sedan XS', ano: 2019, preco: 80000 };
19 | console.log(carro);
20 | // ==> Functions [Type Annotation]
21 | function multiplicarNumero(num1, num2) {
22 | return num1 * num2;
23 | }
24 | console.log(multiplicarNumero(2, 5));
25 |
--------------------------------------------------------------------------------
/modulo-02/08-aula-type-annotation/typeAnnotation.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable prettier/prettier */
2 | /**
3 | * arquivo: typeAnnotation.ts
4 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Type Annotation'
5 | * data: 16/02/2021
6 | * author: Glaucia Lemos <@glaucia_lemos86>
7 | * doc referência: https://www.typescriptlang.org/docs/handbook/2/everyday-types.html
8 | * Transpilação do arquivo: CTRL + SHIFT + B -> tsc: build/watch
9 | */
10 |
11 | export { };
12 |
13 | // ==> Variáveis [Type Annotations]
14 | let nome: string = 'Glaucia Lemos';
15 | console.log(nome);
16 |
17 | // ==> Arrays [Type Annotations]
18 | let animais: string[] = ['Elefante', 'Cachorro', 'Gato', 'Panda', 'Girafa'];
19 | console.log(animais);
20 |
21 | // ==> Objetos [Type Annotations]
22 | let carro: {
23 | nome: string;
24 | ano: number;
25 | preco: number;
26 | };
27 |
28 | carro = { nome: 'Toyota Yaris Sedan XS', ano: 2019, preco: 80000 };
29 | console.log(carro);
30 |
31 | // ==> Functions [Type Annotation]
32 | function multiplicarNumero(num1: number, num2: number) {
33 | return num1 * num2;
34 | }
35 |
36 | console.log(multiplicarNumero(2, 5));
37 |
--------------------------------------------------------------------------------
/modulo-02/10-aula-tipo-boolean/booleanType.js:
--------------------------------------------------------------------------------
1 | "use strict";
2 | /**
3 | * arquivo: booleanType.ts
4 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Tipo Boolean'
5 | * data: 17/02/2021
6 | * author: Glaucia Lemos <@glaucia_lemos86>
7 | * doc referência: https://www.typescriptlang.org/docs/handbook/basic-types.html#boolean
8 | * Transpilação do arquivo: CTRL + SHIFT + B -> tsc: build/watch
9 | */
10 | // ==> Exemplo 01
11 | let tarefaConcluida = true;
12 | let tarefaPendente = false;
13 | console.log(tarefaConcluida);
14 | console.log(tarefaPendente);
15 | // ==> Exemplo 02
16 | let concluido = false;
17 | if (!concluido) {
18 | console.log('Tarefa foi concluída com sucesso!');
19 | }
20 | else {
21 | console.log('Tarefa Pendente!');
22 | }
23 |
--------------------------------------------------------------------------------
/modulo-02/10-aula-tipo-boolean/booleanType.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: booleanType.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Tipo Boolean'
4 | * data: 17/02/2021
5 | * author: Glaucia Lemos <@glaucia_lemos86>
6 | * doc referência: https://www.typescriptlang.org/docs/handbook/basic-types.html#boolean
7 | * Transpilação do arquivo: CTRL + SHIFT + B -> tsc: build/watch
8 | */
9 |
10 | // ==> Exemplo 01
11 |
12 | let tarefaConcluida: boolean = true;
13 | let tarefaPendente: boolean = false;
14 |
15 | console.log(tarefaConcluida);
16 | console.log(tarefaPendente);
17 |
18 | // ==> Exemplo 02
19 |
20 | let concluido: boolean = false;
21 |
22 | if (!concluido) {
23 | console.log('Tarefa foi concluída com sucesso!')
24 | } else {
25 | console.log('Tarefa Pendente!');
26 | }
27 |
--------------------------------------------------------------------------------
/modulo-02/12-aula-number-bigint/numberBigint.js:
--------------------------------------------------------------------------------
1 | "use strict";
2 | /**
3 | * arquivo: numberBigint.ts
4 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Tipo number e bigint'
5 | * data: 17/02/2021
6 | * author: Glaucia Lemos <@glaucia_lemos86>
7 | * doc referência: https://www.typescriptlang.org/docs/handbook/basic-types.html#number
8 | * doc referência: https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-2.html#bigint
9 | * Transpilação do arquivo: CTRL + SHIFT + B -> tsc: build/watch
10 | */
11 | // ==> Exemplos: number
12 | let num1 = 23.0;
13 | let num2 = 0x78CF;
14 | let num3 = 0o577;
15 | let num4 = 0b110001;
16 | console.log('Number - Ponto Flutuante...: ', num1);
17 | console.log('Number - Hexadecimal...: ', num2);
18 | console.log('Number - Octal...: ', num3);
19 | console.log('Number - Binário...: ', num4);
20 | // ==> Exemplos: bigint
21 | let big1 = 9007199254740991n;
22 | let big2 = 9007199254740995n;
23 | ;
24 | let big3 = 0x20000000000003n;
25 | let big4 = 9007199254740995n;
26 | console.log('Bigint...: ', big1);
27 | console.log('Bigint - Binário...: ', big2);
28 | console.log('Bigint - Hexadecimal...: ', big3);
29 | console.log('Bigint - Octal...: ', big4);
30 |
--------------------------------------------------------------------------------
/modulo-02/12-aula-number-bigint/numberBigint.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: numberBigint.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Tipo number e bigint'
4 | * data: 17/02/2021
5 | * author: Glaucia Lemos <@glaucia_lemos86>
6 | * doc referência: https://www.typescriptlang.org/docs/handbook/basic-types.html#number
7 | * doc referência: https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-2.html#bigint
8 | * Transpilação do arquivo: CTRL + SHIFT + B -> tsc: build/watch
9 | */
10 |
11 | // ==> Exemplos: number
12 |
13 | let num1: number = 23.0;
14 | let num2: number = 0x78CF;
15 | let num3: number = 0o577;
16 | let num4: number = 0b110001;
17 |
18 | console.log('Number - Ponto Flutuante...: ', num1);
19 | console.log('Number - Hexadecimal...: ', num2);
20 | console.log('Number - Octal...: ', num3);
21 | console.log('Number - Binário...: ', num4);
22 |
23 | // ==> Exemplos: bigint
24 |
25 | let big1: bigint = 9007199254740991n;
26 | let big2: bigint = 0b100000000000000000000000000000000000000000000000000011n;;
27 | let big3: bigint = 0x20000000000003n;
28 | let big4: bigint = 0o400000000000000003n;
29 |
30 | console.log('Bigint...: ', big1);
31 | console.log('Bigint - Binário...: ', big2);
32 | console.log('Bigint - Hexadecimal...: ', big3);
33 | console.log('Bigint - Octal...: ', big4);
--------------------------------------------------------------------------------
/modulo-02/14-aula-tipo-string/stringType.js:
--------------------------------------------------------------------------------
1 | "use strict";
2 | /**
3 | * arquivo: stringType.ts
4 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Tipo String'
5 | * data: 14/03/2021
6 | * author: Glaucia Lemos <@glaucia_lemos86>
7 | * doc referência: https://www.typescriptlang.org/docs/handbook/basic-types.html#boolean
8 | * Transpilação do arquivo: CTRL + SHIFT + B -> tsc: build/watch
9 | */
10 | // ==> Exemplo 01 - Single Quotes
11 | let nomeCompleto = 'Glaucia Lemos';
12 | console.log(nomeCompleto);
13 | // ==> Exemplo 02 - Double Quotes
14 | let funcaoEmpresa = "Cloud Advocate em JavaScript";
15 | console.log(funcaoEmpresa);
16 | // ==> Exemplo 03 - Back Ticks
17 | let nomeEmpresa = 'Microsoft';
18 | let dadosFuncionario = `Seja bem-vinda ${nomeCompleto}! Você será ${funcaoEmpresa}
19 | na empresa ${nomeEmpresa}`;
20 | console.log(dadosFuncionario);
21 |
--------------------------------------------------------------------------------
/modulo-02/14-aula-tipo-string/stringType.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: stringType.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Tipo String'
4 | * data: 14/03/2021
5 | * author: Glaucia Lemos <@glaucia_lemos86>
6 | * doc referência: https://www.typescriptlang.org/docs/handbook/basic-types.html#boolean
7 | * Transpilação do arquivo: CTRL + SHIFT + B -> tsc: build/watch
8 | */
9 |
10 | // ==> Exemplo 01 - Single Quotes
11 |
12 | let nomeCompleto: string = 'Glaucia Lemos';
13 | console.log(nomeCompleto);
14 |
15 | // ==> Exemplo 02 - Double Quotes
16 |
17 | let funcaoEmpresa: string = "Cloud Advocate em JavaScript";
18 | console.log(funcaoEmpresa);
19 |
20 | // ==> Exemplo 03 - Back Ticks
21 |
22 | let nomeEmpresa: string = 'Microsoft';
23 |
24 | let dadosFuncionario: string = `Seja bem-vinda ${nomeCompleto}! Você será ${funcaoEmpresa}
25 | na empresa ${nomeEmpresa}`;
26 |
27 | console.log(dadosFuncionario);
28 |
--------------------------------------------------------------------------------
/modulo-02/16-aula-tipo-array/arrayType.js:
--------------------------------------------------------------------------------
1 | "use strict";
2 | /**
3 | * arquivo: arrayType.ts
4 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Tipo Array'
5 | * data: 28/03/2021
6 | * author: Glaucia Lemos
7 | * doc referência: https://www.typescriptlang.org/docs/handbook/basic-types.html#array
8 | * Transpilação do arquivo: CTRL + SHIFT + B -> tsc: build/watch
9 | */
10 | // ==> Exemplo 01 - Uso de Colchetes:
11 | let frutas = ['🍍', '🍊', '🍎', '🍉', '🥭'];
12 | console.log(frutas[2]);
13 | // ==> Exemplo 02 - Array Object (Objeto Array):
14 | let frutas1 = ['🍍', '🍊', '🍎', '🍉', '🥭'];
15 | console.log(frutas1[3]);
16 | // ==> Exemplo 03 - Adicionando mais strings com método 'push'
17 | let idiomas = ['Português', 'Inglês', 'Espanhol', 'Francês'];
18 | console.log(idiomas);
19 | idiomas.push('Mandarim');
20 | console.log(idiomas);
21 | idiomas.push('Italiano');
22 | console.log(idiomas);
23 | // ==> Exemplo 04 - Identificar tamanho do array - método 'length'
24 | let idiomas1 = ['Português', 'Inglês', 'Espanhol', 'Francês'];
25 | console.log(idiomas1.length);
26 | // ==> Exemplo 05 - Exemplo de Array com Spread Operator
27 | let listaNumeros = [0, 1, 2, 3, 4, 5];
28 | listaNumeros = [...listaNumeros, 6, 7, 8, 9, 10];
29 | console.log(listaNumeros);
30 | // ==> Exemplo 06 - Exemplo de Array com laço de iteração
31 | let linguagensArray = new Array('JavaScript', 'Python', 'PHP', 'C#');
32 | function funcaoLinguagens(linguagens) {
33 | for (let i = 0; i < linguagens.length; i++) {
34 | console.log(linguagensArray[i]);
35 | }
36 | }
37 | funcaoLinguagens(linguagensArray);
38 |
--------------------------------------------------------------------------------
/modulo-02/16-aula-tipo-array/arrayType.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: arrayType.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Tipo Array'
4 | * data: 28/03/2021
5 | * author: Glaucia Lemos
6 | * doc referência: https://www.typescriptlang.org/docs/handbook/basic-types.html#array
7 | * Transpilação do arquivo: CTRL + SHIFT + B -> tsc: build/watch
8 | */
9 |
10 | // ==> Exemplo 01 - Uso de Colchetes:
11 |
12 | let frutas: string[] = ['🍍', '🍊', '🍎', '🍉', '🥭'];
13 | console.log(frutas[2]);
14 |
15 | // ==> Exemplo 02 - Array Object (Objeto Array):
16 |
17 | let frutas1: Array = ['🍍', '🍊', '🍎', '🍉', '🥭'];
18 | console.log(frutas1[3]);
19 |
20 | // ==> Exemplo 03 - Adicionando mais strings com método 'push'
21 |
22 | let idiomas: Array = ['Português', 'Inglês', 'Espanhol', 'Francês'];
23 | console.log(idiomas);
24 | idiomas.push('Mandarim');
25 | console.log(idiomas);
26 | idiomas.push('Italiano');
27 | console.log(idiomas);
28 |
29 | // ==> Exemplo 04 - Identificar tamanho do array - método 'length'
30 |
31 | let idiomas1: Array = ['Português', 'Inglês', 'Espanhol', 'Francês'];
32 | console.log(idiomas1.length);
33 |
34 | // ==> Exemplo 05 - Exemplo de Array com Spread Operator
35 |
36 | let listaNumeros = [0, 1, 2, 3, 4, 5];
37 | listaNumeros = [...listaNumeros, 6, 7, 8, 9, 10];
38 |
39 | console.log(listaNumeros);
40 |
41 | // ==> Exemplo 06 - Exemplo de Array com laço de iteração
42 |
43 | let linguagensArray:string[] = new Array('JavaScript', 'Python', 'PHP', 'C#');
44 |
45 | function funcaoLinguagens(linguagens:string[]) {
46 | for (let i = 0; i < linguagens.length; i++) {
47 | console.log(linguagensArray[i]);
48 | }
49 | }
50 |
51 | funcaoLinguagens(linguagensArray);
--------------------------------------------------------------------------------
/modulo-02/18-aula-tipo-tuple/tupleType.js:
--------------------------------------------------------------------------------
1 | "use strict";
2 | /**
3 | * arquivo: tupleType.ts
4 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Tipo Tuple'
5 | * data: 28/03/2021
6 | * author: Glaucia Lemos
7 | * doc referência: https://www.typescriptlang.org/docs/handbook/basic-types.html#tuple
8 | * Transpilação do arquivo: CTRL + SHIFT + B -> tsc: build/watch
9 | */
10 | // ==> Exemplo 01 - Uso simples de Tuplas em TypeScript
11 | let pessoa;
12 | pessoa = ['Glaucia Lemos', 'Cloud Advocate JavaScript', 34];
13 | // pessoa = [34, 'Cloud Advocate JavaScript', 'Glaucia Lemos'];
14 | console.log(pessoa);
15 | // ==> Exemplo 02 - Acessando o valor da Tupla
16 | let pessoa1;
17 | pessoa1 = ['Glaucia Lemos', 'Cloud Advocate JavaScript', 34];
18 | console.log(pessoa1[1]);
19 | // ==> Exemplo 03 - Outra forma de usar Tuplas em TypeScrit (com labels)
20 | let pessoa2 = ['Glaucia Lemos', 'Cloud Advocate JavaScript', 34];
21 | console.log(pessoa2);
22 | // ==> Exemplo 04 - Usando Tuplas com Spread Operator
23 | let listaFrutas = ['🍍', '🍊', '🍎', '🍉', '🥭'];
24 | console.log(...listaFrutas);
25 | //==> Exemplo 05 - Lista Heterogênea de Tupla:
26 | let listaFrutas2 = [5, true, ...listaFrutas];
27 | console.log(listaFrutas2);
28 | // ==> Exemplo 06 - Uso de função com Tuplas
29 | function listarPessoas(nomes, idades) {
30 | return [...nomes, ...idades];
31 | }
32 | let resultado = listarPessoas(['Glaucia', 'Jurema'], [34, 68]);
33 | console.log(resultado);
34 | function criarPessoa(...nome) {
35 | return [...nome];
36 | }
37 | console.log(criarPessoa('Glaucia', 'Lemos'));
38 | console.log(criarPessoa('Glaucia', 'de Souza', 'Lemos'));
39 |
--------------------------------------------------------------------------------
/modulo-02/18-aula-tipo-tuple/tupleType.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: tupleType.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Tipo Tuple'
4 | * data: 28/03/2021
5 | * author: Glaucia Lemos
6 | * doc referência: https://www.typescriptlang.org/docs/handbook/basic-types.html#tuple
7 | * Transpilação do arquivo: CTRL + SHIFT + B -> tsc: build/watch
8 | */
9 |
10 | // ==> Exemplo 01 - Uso simples de Tuplas em TypeScript
11 |
12 | let pessoa: [string, string, number];
13 | pessoa = ['Glaucia Lemos', 'Cloud Advocate JavaScript', 34];
14 | // pessoa = [34, 'Cloud Advocate JavaScript', 'Glaucia Lemos'];
15 |
16 | console.log(pessoa);
17 |
18 | // ==> Exemplo 02 - Acessando o valor da Tupla
19 |
20 | let pessoa1: [string, string, number];
21 | pessoa1 = ['Glaucia Lemos', 'Cloud Advocate JavaScript', 34];
22 |
23 | console.log(pessoa1[1]);
24 |
25 | // ==> Exemplo 03 - Outra forma de usar Tuplas em TypeScrit (com labels)
26 | let pessoa2: [nome: string, posicao: string, idade: number] = ['Glaucia Lemos', 'Cloud Advocate JavaScript', 34];
27 |
28 | console.log(pessoa2);
29 |
30 |
31 | // ==> Exemplo 04 - Usando Tuplas com Spread Operator
32 |
33 | let listaFrutas: [string, ...string[]] = ['🍍', '🍊', '🍎', '🍉', '🥭'];
34 | console.log(...listaFrutas);
35 |
36 | //==> Exemplo 05 - Lista Heterogênea de Tupla:
37 |
38 | let listaFrutas2: [number, boolean, ...string[]] = [5, true, ...listaFrutas];
39 | console.log(listaFrutas2);
40 |
41 | // ==> Exemplo 06 - Uso de função com Tuplas
42 |
43 | function listarPessoas(nomes: string[], idades: number[]) {
44 | return [...nomes, ...idades];
45 | }
46 |
47 | let resultado = listarPessoas(['Glaucia', 'Jurema'], [34, 68]);
48 | console.log(resultado)
49 |
50 | // ==> Exemplo 07 - Labeled Tuples com Spread Operator numa função
51 |
52 | type Nome =
53 | | [primeiroNome: string, sobrenome: string]
54 | | [primeiroNome: string, nomeMeio: string, sobrenome: string]
55 |
56 | function criarPessoa(...nome: Nome) {
57 | return [...nome];
58 | }
59 |
60 | console.log(criarPessoa('Glaucia', 'Lemos'));
61 | console.log(criarPessoa('Glaucia', 'de Souza', 'Lemos'));
--------------------------------------------------------------------------------
/modulo-02/20-aula-tipo-enum/enumType.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: enumType.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Tipo Tuple'
4 | * data: 20/06/2021
5 | * author: Glaucia Lemos
6 | * doc referência: https://www.typescriptlang.org/docs/handbook/basic-types.html#enum
7 | * Transpilação do arquivo: CTRL + SHIFT + B -> tsc: build/watch
8 | */
9 |
10 | // ==> Exemplo 01: Numeric Enums (Enums Numérico)
11 |
12 | enum Idioma {
13 | Portugues,
14 | Espanhol,
15 | Ingles,
16 | Frances,
17 | }
18 |
19 | console.log(Idioma);
20 |
21 | // ==> Exemplo 02: String Enums
22 |
23 | enum Dia {
24 | Segunda = 'SEG',
25 | Terca = 'TER',
26 | Quarta = 'QUA',
27 | Quinta = 'QUI',
28 | Sexta = 'SEX',
29 | Sabado = 'SAB',
30 | Domingo = 'DOM',
31 | }
32 |
33 | console.log(Dia);
34 |
35 | // ==> Exemplo 03: Como podemos acessar um valor de um Enum com uma chave: (usando o const)
36 |
37 | /*const enum Comida {
38 | Hamburger,
39 | Massa,
40 | Pizza,
41 | Torta,
42 | Churrasco,
43 | }
44 |
45 | function comida(c: Comida) {
46 | return 'Comidas muito apetitosas!';
47 | }
48 |
49 | console.log(comida(Comida.Pizza));
50 | console.log(comida(Comida.Churrasco));
51 | console.log(comida(5));*/
52 |
53 | const enum Comida {
54 | Hamburger = 'Hamburger',
55 | Massa = 'Massa',
56 | Pizza = 'Pizza',
57 | Torta = 'Torta',
58 | Churrasco = 'Churrasco',
59 | }
60 |
61 | function comida(c: Comida) {
62 | return 'Comidas muito apetitosas!';
63 | }
64 |
65 | console.log(comida(Comida.Pizza));
66 | console.log(comida(Comida.Churrasco));
67 | // console.log(comida(5));
68 |
69 | // ==> Exemplo 04: Quando usar enum?!
70 | enum Tarefa {
71 | Todo,
72 | Progress,
73 | Done,
74 | }
75 |
76 | const concluidaTarefa = {
77 | id: 1,
78 | status: Tarefa.Done,
79 | descricao: 'Parabéns! Tarefa concluída com sucesso!',
80 | };
81 |
82 | if (concluidaTarefa.status === Tarefa.Done) {
83 | console.log('Enviar e-mail: Tarefa Concluída!');
84 | }
85 |
--------------------------------------------------------------------------------
/modulo-02/22-aula-tipo-any/anyType.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: anyType.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Tipo Any'
4 | * data: 27/07/2021
5 | * author: Glaucia Lemos
6 | * doc referência: https://www.typescriptlang.org/docs/handbook/basic-types.html#any
7 | */
8 |
9 | // ==> Exemplo 01: Tipo Any
10 | const a: any = 34;
11 | const b: any = ['Glaucia'];
12 |
13 | const result = a + b;
14 | console.log(result);
15 |
16 | // ==> Exemplo 02: Quando o tipo 'any' é inferido implícitamente
17 | /*let frase;
18 | frase = 'Oi, pessoal! Tudo bem?';
19 |
20 | console.log(frase);*/
21 |
22 | // ==> Exemplo 03: Quando devemos usar o tipo any?!
23 |
24 | const formulario: { [campoFomulario: string]: any } = {
25 | nome: 'Glaucia',
26 | sobrenome: 'Lemos',
27 | idade: 34,
28 | };
29 |
30 | console.log(formulario);
31 |
--------------------------------------------------------------------------------
/modulo-02/24-aula-tipo-unknown/unknownType.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: unknownType.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Tipo Uknown'
4 | * data: 27/07/2021
5 | * author: Glaucia Lemos
6 | * doc referência: https://www.typescriptlang.org/docs/handbook/basic-types.html#unknown
7 | */
8 |
9 | // ==> Exemplo 01: Tipo Unknown
10 |
11 | let valorVariavel: unknown;
12 |
13 | valorVariavel = true;
14 | valorVariavel = 123;
15 | valorVariavel = [];
16 | valorVariavel = 'Oi! Tudo bem?';
17 |
18 | // console.log(valorVariavel);
19 |
20 | // ===> Exemplo 02: Erro ao tentar atribuir um valor do tipo 'unknown' a outros tipos!
21 |
22 | /*let valor: unknown;
23 |
24 | let valor1: boolean = valor;
25 | let valor2: any = valor;
26 | let valor3: any[] = valor;
27 | let valor4: string = valor;*/
28 |
29 | // ===> Exemplo 03: diferença entre: 'any' vs 'unknown'
30 |
31 | let algumaCoisaAny: any;
32 | let algumaCoisaUnknown: unknown;
33 |
34 | console.log(algumaCoisaAny.toFixed());
35 |
36 | if (typeof algumaCoisaUnknown === 'number') {
37 | console.log(algumaCoisaUnknown.toFixed());
38 | }
39 |
--------------------------------------------------------------------------------
/modulo-02/26-aula-tipo-void/voidType.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: voidType.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre o tipo 'void'
4 | * data: 27/08/2021
5 | * author: Glaucia Lemos
6 | * doc referência: https://www.typescriptlang.org/docs/handbook/basic-types.html#void
7 | */
8 |
9 | // ==> Exemplo 01 - funções:
10 |
11 | function logError(errorMessage: string): void {
12 | console.log(errorMessage);
13 | // return errorMessage;
14 | }
15 |
16 | logError('Required field - Name!');
17 |
18 | // ==> Exemplo 02 - funções:
19 |
20 | const logErrorExample2 = (errorMessage: string): void => {
21 | console.log(errorMessage);
22 | };
23 |
24 | logErrorExample2('Required field - Surname');
25 |
26 | // ==> Exemplo void: variáveis
27 |
28 | let variavelExemploVoid: void;
29 | // variavelExemploVoid = 1;
30 | variavelExemploVoid = null;
31 | variavelExemploVoid = undefined;
32 |
33 | console.log(variavelExemploVoid);
34 |
--------------------------------------------------------------------------------
/modulo-02/28-aula-null-undefined/nullUndefinedType.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable prefer-const */
2 | /**
3 | * arquivo: nullUndefinedType.ts
4 | * descrição: arquivo responsável por ensinar conceitos básicos sobre os tipos 'null' e 'undefined'
5 | * data: 14/09/2021
6 | * author: Glaucia Lemos
7 | * doc referência: https://www.typescriptlang.org/docs/handbook/basic-types.html
8 | */
9 |
10 | // ==> Exemplo 01: Null
11 |
12 | let variavelTesteNull = null;
13 |
14 | console.log(variavelTesteNull);
15 | console.log(typeof variavelTesteNull);
16 |
17 | // ==> Exemplo 02: Undefined
18 |
19 | let variavelTesteUndefined;
20 |
21 | console.log(variavelTesteUndefined);
22 | console.log(typeof variavelTesteUndefined);
23 |
24 | // ==> Diferenças e Similaridades: Null vs Undefined
25 |
26 | console.log('Exemplo 01:', null == undefined);
27 | console.log('Exemplo 02:', null === undefined);
28 |
--------------------------------------------------------------------------------
/modulo-02/30-aula-tipo-never/neverType.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: neverType.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre o tipo 'never'
4 | * data: 11/11/2021
5 | * author: Glaucia Lemos
6 | * doc referência: https://www.typescriptlang.org/docs/handbook/basic-types.html#never
7 | */
8 |
9 | // ==> Exemplo 01: Never - Throw Exception
10 |
11 | function error(message: string): never {
12 | throw new Error(message);
13 | }
14 |
15 | console.log(error('Erro de Mensagem - 01'));
16 |
17 | // ==> Exemplo 02: Never inferido automaticamente
18 | function rejectMessage() {
19 | return error('Error de Mensagem - 02');
20 | }
21 |
22 | console.log(rejectMessage());
23 |
24 | // ==> Exemplo 03 - Função que contém loop infinito retorna o tipo 'never'
25 |
26 | const loopInfinito = function loop() {
27 | // eslint-disable-next-line no-constant-condition
28 | while (true) {
29 | console.log('Oi, Developers!');
30 | }
31 | };
32 |
33 | // console.log(loopInfinito());
34 |
35 | // ==> Exemplo 04: Diferença entre os tipos: 'never' x 'void'
36 |
37 | const algumaCoisaVoid: void = null;
38 |
39 | // ==> dará erro! (// Error: Type 'null' is not assignable to type 'never')
40 | // const algumaCoisaNever: never = null;
41 |
42 | //console.log(algumaCoisaVoid);
43 | //console.log(algumaCoisaNever);
44 |
--------------------------------------------------------------------------------
/modulo-02/32-aula-tipo-object/objectType.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable prettier/prettier */
2 | /**
3 | * arquivo: objectType.ts
4 | * descrição: arquivo responsável por ensinar conceitos básicos sobre o tipo 'object'
5 | * data: 26/11/2021
6 | * author: Glaucia Lemos
7 | * doc referência: https://www.typescriptlang.org/docs/handbook/2/objects.html
8 | */
9 | export { };
10 |
11 | // ==> Exemplo 01 -> Exemplo básico do uso do Type Object
12 |
13 | const pessoa = {
14 | nome: 'Glaucia',
15 | sobrenome: 'Lemos',
16 | idade: 35,
17 | funcao: 'Cloud Advocate'
18 | };
19 |
20 | console.log(pessoa);
21 |
22 | // ==> Exemplo 02 -> object como parâmetros de função (eles podem ser anônimos)
23 | function onboarding01(funcionario: { nome: string }) {
24 | return 'Seja bem-vinda ' + funcionario.nome;
25 | }
26 |
27 | console.log(onboarding01({ nome: 'Glaucia Lemos' }));
28 |
29 | // ==> Exemplo 03 -> object nomeados
30 |
31 | interface Pessoa {
32 | nome: string;
33 | funcao: string;
34 | }
35 |
36 | function onboarding02(pessoa: Pessoa) {
37 | return (
38 | 'Seja bem-vinda ' +
39 | pessoa.nome +
40 | '!' +
41 | ' Sua função aqui na empresa será ' +
42 | pessoa.funcao +
43 | '.'
44 | );
45 | }
46 |
47 | console.log(onboarding02({ nome: 'Glaucia Lemos', funcao: 'Cloud Advocate' }));
48 |
49 | // ==> Exemplo 04 -> object como type alias
50 |
51 | type Pessoa03 = {
52 | nome: string;
53 | funcao: string;
54 | linguagem: string;
55 | }
56 |
57 | function onboarding03(pessoa: Pessoa03) {
58 | return (
59 | 'Seja bem-vinda ' +
60 | pessoa.nome +
61 | '!' +
62 | ' Sua função aqui na empresa será ' +
63 | pessoa.funcao +
64 | '.' +
65 | ' Você trabalhará com a linguagem ' +
66 | pessoa.linguagem +
67 | '.'
68 | );
69 | }
70 |
71 | console.log(onboarding03({ nome: 'Glaucia Lemos', funcao: 'Cloud Advocate', linguagem: 'JavaScript/Typescript' }));
72 |
73 |
74 | // ==> Exemplo 05 -> usando optional no object
75 |
76 | interface Pessoa04 {
77 | nome: string;
78 | funcao: string;
79 | linguagem: string;
80 | email?: string;
81 | }
82 |
83 | function onboarding04(pessoa: Pessoa04) {
84 | return (
85 | 'Seja bem-vinda ' +
86 | pessoa.nome +
87 | '!' +
88 | ' Sua função aqui na empresa será ' +
89 | pessoa.funcao +
90 | '.' +
91 | ' Você trabalhará com a linguagem ' +
92 | pessoa.linguagem +
93 | '.'
94 | );
95 | }
96 |
97 | console.log(onboarding04({ nome: 'Glaucia Lemos', funcao: 'Cloud Advocate', linguagem: 'JavaScript/Typescript' }));
98 |
99 | // ==> Exemplo 06 -> Propriedade 'readonly' (se deseja proibir que os devs não modifiquem um determinado objeto use o '
100 | //readonly)
101 |
102 | interface Pessoa05 {
103 | nome: string;
104 | funcao: string;
105 | linguagem: string;
106 | readonly email: string;
107 | }
108 |
109 | function onboarding05(pessoa: Pessoa05) {
110 | return (
111 | 'Seja bem-vinda ' +
112 | pessoa.nome +
113 | '!' +
114 | ' Sua função aqui na empresa será ' +
115 | pessoa.funcao +
116 | '.' +
117 | ' Você trabalhará com a linguagem ' +
118 | pessoa.linguagem +
119 | '.' +
120 | ' Seu e-mail será ' +
121 | pessoa.email
122 | );
123 | }
124 |
125 | console.log(onboarding05(
126 | {
127 | nome: 'Glaucia Lemos',
128 | funcao: 'Cloud Advocate',
129 | linguagem: 'JavaScript/Typescript',
130 | email: 'gllemos@microsoft.com'
131 | }
132 | ));
133 |
134 | // ==> Exemplo 07 -> tipos de extensões (heranças)
135 | interface Mae {
136 | nome: string;
137 | }
138 |
139 | interface Pai {
140 | sobrenome: string;
141 | }
142 |
143 | interface Filha extends Mae, Pai {
144 | idade: number;
145 | }
146 |
147 | const filha: Filha = {
148 | nome: 'Glaucia',
149 | sobrenome: 'Lemos',
150 | idade: 35
151 | }
152 |
153 | console.log(filha);
154 |
155 | // ==> Exemplo 08 -> Tipos de Interseções
156 |
157 | interface Cachorro {
158 | tipo: string;
159 | }
160 |
161 | interface Gato {
162 | tipo: string;
163 | }
164 |
165 | type Animal = Cachorro & Gato;
166 |
167 | // Exemplo 09 - Generic Objects
168 |
169 | type Usuario = {
170 | nome: string;
171 | email: string;
172 | }
173 |
174 | type Admin = {
175 | nome: string;
176 | email: string;
177 | admin: true;
178 | }
179 |
180 | const usuario: Usuario = {
181 | nome: 'Glaucia Lemos',
182 | email: 'algumacoisa@gmail.com'
183 | }
184 |
185 | const admin: Admin = {
186 | nome: 'Glaucia Lemos',
187 | email: 'algumacoisa@gmail.com',
188 | admin: true
189 | }
190 |
191 | function acessarSistema(usuario: T): T {
192 | return usuario;
193 | }
194 |
195 | console.log(acessarSistema(usuario));
196 | console.log(acessarSistema(admin));
197 |
198 | /*function acessarSistema(usuario: Usuario): Usuario {
199 | return usuario;
200 | };*/
201 |
202 | // console.log(acessarSistema(usuario));
203 |
--------------------------------------------------------------------------------
/modulo-02/README.md:
--------------------------------------------------------------------------------
1 | # Módulo 2: Tipos Básicos
2 |
3 | Aqui vocês encontrarão todos os vídeos e os exemplos desenvolvidos durante o módulo 02.
4 |
5 | ## 💻 Série de Vídeos
6 |
7 | | Vídeo Aula | Descrição |
8 | | ---------------------------------------------- | ----------------------------------- |
9 | | **[Vídeo 07](https://youtu.be/ocjS96i27zk)** | Vídeo 07 - Type Annotation |
10 | | **[Vídeo 08](https://youtu.be/BmLMwwWNblI)** | Vídeo 08 - Demo: Type Annotation |
11 | | **[Vídeo 09](https://youtu.be/y6dgaE-cPhc)** | Vídeo 09 - Boolean |
12 | | **[Vídeo 10](https://youtu.be/SkXMjanTPbQ)** | Vídeo 10 - Demo: Boolean |
13 | | **[Vídeo 11](https://youtu.be/SsQqZPdPJl4)** | Vídeo 11 - Number & Bigint |
14 | | **[Vídeo 12](https://youtu.be/498uRBCoGf8)** | Vídeo 12 - Demo: Number & Bigint |
15 | | **[Vídeo 13](https://youtu.be/0LpB1I8YPnA)** | Vídeo 13 - String |
16 | | **[Vídeo 14](https://youtu.be/Le9jY9AdWbI)** | Vídeo 14 - Demo: String |
17 | | **[Vídeo 15](https://youtu.be/IzEpibKEtg4)** | Vídeo 15 - Array |
18 | | **[Vídeo 16](https://youtu.be/P1ZALg3mKtA)** | Vídeo 16 - Demo: Array |
19 | | **[Vídeo 17](https://youtu.be/APecrHh9K7E)** | Vídeo 17 - Tuple |
20 | | **[Vídeo 18](https://youtu.be/Hz1mB0YwDWU)** | Vídeo 18 - Demo: Tuple - Parte 01 |
21 | | **[Vídeo 18.1](https://youtu.be/0_61ggJ_yzY)** | Vídeo 18 - Demo: Tuple - Parte 02 |
22 | | **[Vídeo 19](https://youtu.be/oBlnDsKloAY)** | Vídeo 19 - Enum |
23 | | **[Vídeo 20](https://youtu.be/aU5rKsHyxHk)** | Vídeo 20 - Demo: Enum |
24 | | **[Vídeo 21](https://youtu.be/VWaPx-pvEn8)** | Vídeo 21 - Any |
25 | | **[Vídeo 22](https://youtu.be/I0wYYGwiDNY)** | Vídeo 22 - Demo: Any |
26 | | **[Vídeo 23](https://youtu.be/7BLsEz7eP6s)** | Vídeo 23 - Unknown |
27 | | **[Vídeo 24](https://youtu.be/6XFn4Gny8WU)** | Vídeo 24 - Demo: Unknown |
28 | | **[Vídeo 25](https://youtu.be/yLraF6_-85U)** | Vídeo 25 - Void |
29 | | **[Vídeo 26](https://youtu.be/Aguo_gIIh7o)** | Vídeo 26 - Demo: Void |
30 | | **[Vídeo 27](https://youtu.be/vyOidIn_YfQ)** | Vídeo 27 - Null and Undefined |
31 | | **[Vídeo 28](https://youtu.be/3Cx3q9aOf_I)** | Vídeo 28 - Demo: Null and Undefined |
32 | | **[Vídeo 29](https://youtu.be/B355hDt29q4)** | Vídeo 29 - Never |
33 | | **[Vídeo 30](https://youtu.be/ZJt15H_MKLc)** | Vídeo 30 - Demo: Never |
34 | | **[Vídeo 31](https://youtu.be/SoZeG6p_Ass)** | Vídeo 31 - Object |
35 | | **[Vídeo 32](https://youtu.be/0cxJ1RQ7Gv0)** | Vídeo 32 - Demo: Object - Parte 01 |
36 | | **[Vídeo 33](https://youtu.be/WNp44xb1M_s)** | Vídeo 33 - Demo: Object - Parte 02 |
37 |
--------------------------------------------------------------------------------
/modulo-03/README.md:
--------------------------------------------------------------------------------
1 | # Módulo 3: Fluxos de Controle
2 |
3 | Aqui vocês encontrarão todos os vídeos e os exemplos desenvolvidos durante o módulo 03.
4 |
5 | ## 💻 Série de Vídeos
6 |
7 | | Vídeo Aula | Descrição |
8 | | -------------------------------------------- | ------------------------------ |
9 | | **[Vídeo 34](https://youtu.be/sU9miGUUJrI)** | Vídeo 34 - If...else |
10 | | **[Vídeo 35](https://youtu.be/_KkjHVo4x_M)** | Vídeo 35 - Demo: If...else |
11 | | **[Vídeo 36](https://youtu.be/-rUHKfnbq7g)** | Vídeo 36 - Switch...case |
12 | | **[Vídeo 37](https://youtu.be/kaKlKebVqco)** | Vídeo 37 - Demo: Switch...case |
13 | | **[Vídeo 38](https://youtu.be/KUi9FhBResg)** | Vídeo 38 - For |
14 | | **[Vídeo 39](https://youtu.be/-yAy5hBuW20)** | Vídeo 39 - Demo: For |
15 | | **[Vídeo 40](https://youtu.be/01Hu8ekpnEc)** | Vídeo 40 - While/do...while |
16 | | **[Vídeo 41](https://youtu.be/h1BpPZyl8j8)** | Vídeo 41 - Demo: While/do...while |
17 |
--------------------------------------------------------------------------------
/modulo-03/aula-35-if-else/if-else.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable prefer-const */
2 | /* eslint-disable prettier/prettier */
3 | /**
4 | * arquivo: ifElse.ts
5 | * descrição: arquivo responsável por ensinar como usar instrução if-else no Typescript
6 | * data: 07/12/2021
7 | * author: Glaucia Lemos
8 | */
9 |
10 | export { };
11 |
12 | // ==> Exemplo 01 - Uso do if
13 |
14 | const numeroMax = 100;
15 | let contador = 100;
16 |
17 | if (contador < numeroMax) {
18 | contador++
19 | }
20 |
21 | console.log(contador);
22 |
23 | // ==> Exemplo 02 - Uso do if
24 |
25 | const permissaoIdadeDirigir = 16;
26 |
27 | if (permissaoIdadeDirigir >= 18) {
28 | console.log('Você está habilitado para dirigir!')
29 | }
30 |
31 | // ==> Exemplo 03 - Uso do if-else
32 |
33 | const permissaoIdadeDirigir01 = 18;
34 |
35 | if (permissaoIdadeDirigir01 <= 17) {
36 | console.log('Você está habilitado para dirigir!')
37 | } else {
38 | console.log('Você não está habilitado para dirigir!')
39 | }
40 |
41 | //==> Exemplo 04 - if... else if
42 |
43 | let desconto: number;
44 |
45 | let valorCompra = 14;
46 |
47 | if (valorCompra > 0 && valorCompra <= 5) {
48 | desconto = 5;
49 | } else if (valorCompra > 5 && valorCompra <= 10) {
50 | desconto = 10;
51 | } else {
52 | desconto = 15;
53 | }
54 |
55 | console.log(`Você teve um desconto de...: ${desconto}% desconto`);
56 |
57 | // ==> Exemplo 05 - Ternário (? :) - if...else
58 |
59 | /*const idadeVotacao = 18;
60 |
61 | if (idadeVotacao >= 18) {
62 | console.log('Você é elegível para votar.')
63 | } else {
64 | console.log('Você não é elegível para votar.')
65 | }*/
66 |
67 | // ==> Ternário
68 | const idadeVotacao = 16;
69 |
70 | const podeVotar = (idadeVotacao >= 18) ? 'Você é elegível para votar.' : 'Você não é elegível para votar.'
71 |
72 | console.log(podeVotar)
73 |
--------------------------------------------------------------------------------
/modulo-03/aula-37-switch-case/switch-case.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable prefer-const */
2 | /* eslint-disable prettier/prettier */
3 | /**
4 | * arquivo: switch-case.ts
5 | * descrição: arquivo responsável por ensinar como usar instrução switch-case no Typescript
6 | * data: 23/12/2021
7 | * author: Glaucia Lemos
8 | */
9 |
10 | export { };
11 |
12 | // ==> Exemplo 01 - Uso do switch...case
13 |
14 | let flor = 'tulipa';
15 |
16 | switch (flor) {
17 | case 'rosa':
18 | console.log('Rosas são vermelhas');
19 | break;
20 | case 'violeta':
21 | console.log('Violetas são azuis');
22 | break;
23 | case 'tulipa':
24 | console.log('Tulipas são brancas');
25 | break;
26 |
27 | default:
28 | console.log('Por favor, selecione uma outra flor!');
29 | }
30 |
31 | // ==> Exemplo 02 - Uso do switch...case
32 |
33 | let diaUtilSemana = 5;
34 |
35 | switch (diaUtilSemana) {
36 | case 0:
37 | console.log('Domingo');
38 | break;
39 | case 1:
40 | console.log('Segunda');
41 | break;
42 | case 2:
43 | console.log('Terça');
44 | break;
45 | case 3:
46 | console.log('Quarta');
47 | break;
48 | case 4:
49 | console.log('Quinta');
50 | break;
51 | case 5:
52 | console.log('Sexta');
53 | break;
54 |
55 | default:
56 | console.log('Não é um dia útil');
57 | }
58 |
--------------------------------------------------------------------------------
/modulo-03/aula-39-loop-for/loop-for.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable prettier/prettier */
2 | /**
3 | * arquivo: loop-for.ts
4 | * descrição: arquivo responsável por ensinar como usar o loop for no Typescript
5 | * data: 23/01/2021
6 | * author: Glaucia Lemos
7 | */
8 |
9 | // ==> Exemplo 01: loop for
10 |
11 | for (let i = 0; i < 10; i++) {
12 | console.log(i);
13 | }
14 |
15 | // ==> Exemplo 02: for ...of - (retorna uma coleção de matriz, lista ou tupla)
16 | const arrayNumeros = [10, 20, 30, 40, 50];
17 |
18 | for (const i of arrayNumeros) {
19 | console.log(i);
20 | }
21 |
22 | // ==> Exemplo 03: for ...in - (retorna uma coleção de matriz, lista ou tupla)
23 |
24 | const arrayNumeros_01 = [5, 4, 3, 2, 1, 0]
25 |
26 | // for (const i in arrayNumeros_01) {
27 | // console.log(i);
28 | // }
29 |
30 | // sort()
31 | const ordemNumerica: number[] = arrayNumeros_01.sort();
32 | console.log(ordemNumerica);
33 |
--------------------------------------------------------------------------------
/modulo-03/aula-41-loop-while/loop-while.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable prettier/prettier */
2 | /**
3 | * arquivo: loop-while.ts
4 | * descrição: arquivo responsável por ensinar como usar o loop for no Typescript
5 | * data: 23/01/2021
6 | * author: Glaucia Lemos
7 | */
8 |
9 | // ==> Exemplo 01 - while
10 | let contador = 0;
11 |
12 | while (contador < 5) {
13 | console.log(contador);
14 | contador++;
15 | }
16 |
17 | // ==> Exemplo 02
18 | let numero = 1;
19 |
20 | while (numero <= 20) {
21 | if (numero % 5 == 0) {
22 | console.log('O primeiro número múltiplo de 5 entre 1 a 20 é...: ', numero);
23 | break;
24 | }
25 | numero++
26 | }
27 |
28 | // ==> Exemplo 03 - exemplo mais prático
29 | let contadorUsuario = 0;
30 | const usuario : string[] = ['Glaucia', 'Jurema', 'Prince'];
31 |
32 | while (usuario[contadorUsuario]) {
33 |
34 | console.log('Usuários...: ', usuario[contadorUsuario]);
35 | contadorUsuario++;
36 | }
37 |
38 | // ==> Exemplo 04 - do...while
39 | let contador_01 = 0;
40 |
41 | do {
42 | console.log(contador_01);
43 | contador_01++
44 | } while (contador_01 < 5)
45 |
--------------------------------------------------------------------------------
/modulo-04/README.md:
--------------------------------------------------------------------------------
1 | # Módulo 4: Funções/Functions
2 |
3 | Aqui vocês encontrarão todos os vídeos e os exemplos desenvolvidos durante o módulo 04.
4 |
5 | ## 💻 Série de Vídeos
6 |
7 | | Vídeo Aula | Descrição |
8 | |---|---|
9 | | **[Vídeo 42](https://youtu.be/AU7-s7Ucock)** | Vídeo 42 - Intro à Funções |
10 | | **[Vídeo 43](https://youtu.be/DHTQwvXcZOs)** | Vídeo 43 - Demo: Funções |
11 | | **[Vídeo 44](https://youtu.be/faHgw09dcsw)** | Vídeo 44 - Optional Parameters |
12 | | **[Vídeo 45](https://youtu.be/8lkQjfuif8c)** | Vídeo 45 - Demo: Optional Parameters |
13 | | **[Vídeo 46](https://youtu.be/zbnwyJybtPg)** | Vídeo 46 - Default Parameters |
14 | | **[Vídeo 47](https://youtu.be/RFyhBnowMOY)** | Vídeo 47 - Demo: Default Parameters |
15 | | **[Vídeo 48](https://youtu.be/GdxGQA8ppk0)** | Vídeo 48 - Rest Parameters |
16 | | **[Vídeo 49](https://youtu.be/hEe0rD4-LVM)** | Vídeo 49 - Demo: Rest Parameters |
17 |
--------------------------------------------------------------------------------
/modulo-04/aula-43-functions/functions.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: function.ts
3 | * descrição: arquivo responsável por ensinar como usar o functions no Typescript
4 | * data: 14/02/2021
5 | * author: Glaucia Lemos
6 | */
7 |
8 | export {};
9 |
10 | // ==> Exemplo 01 - Functions (Named function)
11 | function somarNumeros(num1: number, num2: number): number {
12 | return num1 + num2;
13 | }
14 |
15 | const resultado = somarNumeros(2, 2);
16 | console.log(resultado);
17 |
18 | // ==> Exemplo 02 - Função Anônima (Function Expression)
19 | const saudar = function (mensagem: string) {
20 | return mensagem;
21 | };
22 |
23 | console.log(saudar('Olá, Developers!'));
24 |
25 | // ==> Exemplo 03 - (Arrow Function Expression)
26 | const saudar_03 = (mensagem: string) => {
27 | return mensagem;
28 | };
29 |
30 | console.log(saudar_03('Fala, Pessoal!'));
31 |
32 | // ==> Exemplo 04 - (Function constructor)
33 | const saudar_04 = new Function('mensagem', 'return "Fala " + mensagem');
34 |
35 | console.log(saudar_04('Galera!'));
36 |
--------------------------------------------------------------------------------
/modulo-04/aula-45-optional-parameters/optionalParameters.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable prefer-const */
2 | /**
3 | * arquivo: optionalParameters.ts
4 | * descrição: arquivo responsável por ensinar como usar o
5 | * 'Optional Parameters' em funções no no Typescript
6 | * data: 14/02/2022
7 | * author: Glaucia Lemos
8 | */
9 |
10 | export {};
11 |
12 | // ==> Exemplo 01 - Optional Parameter
13 | function informarDadosPessoa(idPessoa: number, nome: string, email?: string) {
14 | console.log('Id Funcionário...: ', idPessoa, 'Nome...: ', nome);
15 |
16 | if (email != undefined) console.log('E-mail...: ', email);
17 | }
18 |
19 | informarDadosPessoa(775544, 'Glaucia Lemos');
20 | informarDadosPessoa(994411, 'Jurema Lemos', 'jurema@example.com');
21 |
22 | // ==> Exemplo 02
23 | function mensagemLog(mensagem: string, usuarioId?: number) {
24 | const horaLog = new Date().toLocaleTimeString();
25 |
26 | console.log(horaLog, mensagem, usuarioId || 'Usuário(a) não conectado(a)');
27 | }
28 |
29 | mensagemLog('Atualizar Página');
30 | mensagemLog('Usuário(a) logado(a) com sucesso');
31 |
32 | // ==> Exemplo 03
33 |
34 | type Pessoa = {
35 | idFuncionario: number;
36 | nome: string;
37 | idade?: number;
38 | email?: string;
39 | };
40 |
41 | let pessoa: Pessoa;
42 |
43 | pessoa = {
44 | idFuncionario: 112233,
45 | nome: 'Glaucia Lemos',
46 | };
47 |
48 | console.log(pessoa);
49 |
--------------------------------------------------------------------------------
/modulo-04/aula-47-default-parameters/defaultParameters.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: defaultParameters.ts
3 | * descrição: arquivo responsável por ensinar como usar o
4 | * 'Default Parameters' em funções no no Typescript
5 | * data: 29/03/2022
6 | * author: Glaucia Lemos
7 | */
8 |
9 | export {};
10 |
11 | // ==> Exemplo 01 - Default Parameters
12 | function descontoCompra(preco: number, desconto = 0.08) {
13 | return preco * (1 - desconto);
14 | }
15 |
16 | console.log(descontoCompra(100)); //92
17 |
18 | // ==> Exemplo 02
19 | function exibirMensagem(mensagem: string, saudar = 'Fala, pessoal!') {
20 | return saudar + ' ' + mensagem + '!';
21 | }
22 |
23 | console.log(exibirMensagem('JavaScript Developers'));
24 |
25 | // ==> Exemplo 03
26 | function exibirNome(nome: string, sobrenome = 'Lemos') {
27 | return nome + ' ' + sobrenome;
28 | }
29 |
30 | const resultado_1 = exibirNome('Glaucia');
31 | const resultado_2 = exibirNome('Glaucia', undefined);
32 | // const resultado_3 = exibirNome('Glaucia', 'de Souza', 'Senhorita');
33 | const resultado_4 = exibirNome('Glaucia', 'de Souza');
34 |
35 | console.log(resultado_1);
36 | console.log(resultado_2);
37 | // console.log(resultado_3);
38 | console.log(resultado_4);
39 |
--------------------------------------------------------------------------------
/modulo-04/aula-49-rest-parameters/restParameters.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: restParameters.ts
3 | * descrição: arquivo responsável por ensinar como usar o
4 | * 'Rest Parameters' em funções no no Typescript
5 | * data: 29/03/2022
6 | * author: Glaucia Lemos
7 | */
8 |
9 | export {};
10 |
11 | // ==> Exemplo 01
12 | function somarNumeros(...numeros: number[]) {
13 | let total = 0;
14 | numeros.forEach((numero) => (total += numero));
15 |
16 | return total;
17 | }
18 |
19 | console.log(somarNumeros(30, 20));
20 | console.log(somarNumeros(40, 50, 50, 40, 20));
21 |
22 | // ==> Exemplo 02
23 | function listarFrutas(frase: string, ...frutas: string[]) {
24 | return frase + ' ' + frutas.join(', ');
25 | }
26 |
27 | console.log(
28 | listarFrutas(
29 | 'Glaucia, você precisa ir na feira para comprar...:',
30 | '🥥',
31 | '🍓',
32 | '🍌',
33 | '🍍',
34 | ),
35 | );
36 |
37 | // ==> Exemplo 03
38 | class Produtos {
39 | public exibirProdutos(...produtos: string[]): void {
40 | for (const produto of produtos) {
41 | console.log(produto);
42 | }
43 | }
44 | }
45 |
46 | const departamentoInformatica: Produtos = new Produtos();
47 | console.log(
48 | 'Todos os produtos do departamento de Informatica disponíveis no estoque...: ',
49 | );
50 |
51 | departamentoInformatica.exibirProdutos(
52 | 'Mouse',
53 | 'Notebook',
54 | 'USB',
55 | 'Monitor',
56 | 'Teclado',
57 | 'WebCam',
58 | );
59 |
--------------------------------------------------------------------------------
/modulo-05/README.md:
--------------------------------------------------------------------------------
1 | # Módulo 5: Classes
2 |
3 | Aqui vocês encontrarão todos os vídeos e os exemplos desenvolvidos durante o módulo 05.
4 |
5 | ## 💻 Série de Vídeos
6 |
7 | | Vídeo Aula | Descrição |
8 | | -------------------------------------------- | -------------------------------------------------- |
9 | | **[Vídeo 50](https://youtu.be/7W3PNpoCB40)** | Vídeo 50 - Intro à Classes |
10 | | **[Vídeo 51](https://youtu.be/tKVsXBMYm1g)** | Vídeo 51 - Demo: Classes |
11 | | **[Vídeo 52](https://youtu.be/tKVsXBMYm1g)** | Vídeo 52 - Modificadores de Acesso |
12 | | **[Vídeo 53](https://youtu.be/1Nq2gE5Bzpo)** | Vídeo 53 - Demo: Modificadores de Acesso |
13 | | **[Vídeo 54](https://youtu.be/tTuiHXKW9v4)** | Vídeo 54 - Modificadores de Acesso: readonly |
14 | | **[Vídeo 55](https://youtu.be/kHzkhKMNyEI)** | Vídeo 55 - Demo: Modificadores de Acesso: readonly |
15 | | **[Vídeo 56](https://youtu.be/5cKzzP4CeKM)** | Vídeo 56 - Uso de Getters & Setters |
16 | | **[Vídeo 57](https://youtu.be/AFYCxTnVQbM)** | Vídeo 57 - Demo - Uso de Getters & Setters |
17 | | **[Vídeo 58](https://youtu.be/GawUXUjgrG8)** | Vídeo 58 - Herança |
18 | | **[Vídeo 59](https://youtu.be/v3X3vk2YGvI)** | Vídeo 59 - Demo - Herança |
19 | | **[Vídeo 60](https://youtu.be/vqhjXC19_WI)** | Vídeo 60 - Membros Estáticos |
20 | | **[Vídeo 61](https://youtu.be/uHy4vhX3LRA)** | Vídeo 61 - Demo - Membros Estáticos |
21 | | **[Vídeo 62](https://youtu.be/BB9aVjqLEJc)** | Vídeo 62 - Classes Abstratas |
22 | | **[Vídeo 63](https://youtu.be/7-W_cJOPa4E)** | Vídeo 63 - Demo - Classes Abstratas |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/modulo-05/aula-51-classes/classes.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: classes.ts
3 | * descrição: arquivo responsável por ensinar como usar o
4 | * 'Classes Typescript
5 | * data: 03/04/2022
6 | * author: Glaucia Lemos
7 | */
8 |
9 | // ==> Exemplo 01 - Classes
10 |
11 | export {};
12 |
13 | class Pessoa {
14 | nome: string;
15 | sobrenome: string;
16 |
17 | constructor(nome: string, sobrenome: string) {
18 | this.nome = nome;
19 | this.sobrenome = sobrenome;
20 | }
21 |
22 | nomeCompleto(): string {
23 | return `${this.nome} ${this.sobrenome}`;
24 | }
25 | }
26 |
27 | const pessoa = new Pessoa('Glaucia', 'Lemos');
28 | console.log(pessoa.nomeCompleto());
29 |
30 | // ==> Exemplo 02 - Classes (sem constructor)
31 | class Estudante {
32 | codigoEstudante: number;
33 | nomeEstudante: string;
34 | }
35 |
36 | // Criar um objeto ou a instancia
37 | const estudante = new Estudante();
38 |
39 | // Inicializar o objeto:
40 | estudante.codigoEstudante = 8967;
41 | estudante.nomeEstudante = 'Prince Lemos';
42 |
43 | // Acessar os campos:
44 | console.log('Código do Estudante...: ' + estudante.codigoEstudante);
45 | console.log('Nome do Estudante...: ' + estudante.nomeEstudante);
46 |
47 | // ==> Exemplo 03 - Classes (com constructor)
48 | class Estudante_1 {
49 | codigoEstudante: number;
50 | nomeEstudante: string;
51 |
52 | // Definir o Construtor
53 | constructor(codigoEstudante: number, nomeEstudante: string) {
54 | this.codigoEstudante = codigoEstudante;
55 | this.nomeEstudante = nomeEstudante;
56 | }
57 |
58 | // Criar o método
59 | listarEstudante(): void {
60 | console.log('Código do Estudante...: ' + this.codigoEstudante);
61 | console.log('Nome do Estudante...: ' + this.nomeEstudante);
62 | }
63 | }
64 |
65 | // Acessar os campos:
66 | const estudante_1 = new Estudante_1(9845, 'Prince Lemos');
67 | console.log(
68 | 'Lendo o atributo Código do Estudante...: ' + estudante_1.codigoEstudante,
69 | );
70 | console.log(
71 | 'Lendo o atributo Nome do Estudante...: ' + estudante_1.nomeEstudante,
72 | );
73 |
--------------------------------------------------------------------------------
/modulo-05/aula-53-access-modifier/accessModifier.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: accessModifier.ts
3 | * descrição: arquivo responsável por ensinar como usar o 'Modificadores de
4 | * Acesso' no Typescript
5 | * data: 12/04/2022
6 | * author: Glaucia Lemos
7 | */
8 |
9 | export {};
10 |
11 | // ==> Exemplo 01- Modificador: public
12 | class Estudante {
13 | codigoEstudante: number;
14 | nomeEstudante: string;
15 | }
16 |
17 | const estudante = new Estudante();
18 | estudante.codigoEstudante = 201;
19 | estudante.nomeEstudante = 'Glaucia Lemos';
20 |
21 | console.log(estudante.codigoEstudante);
22 | console.log(estudante.nomeEstudante);
23 |
24 | // ==> Exemplo 02 - Modificador: private
25 | class Estudante_02 {
26 | codigoEstudante: number;
27 | nomeEstudante: string;
28 | private idade: number;
29 |
30 | constructor(codigEstudante: number, nomeEstudante: string, idade: number) {
31 | this.codigoEstudante = codigEstudante;
32 | this.nomeEstudante = nomeEstudante;
33 | this.idade = idade;
34 | }
35 |
36 | retornarDadosEstudante() {
37 | return `Código do Aluno...: ${this.codigoEstudante}.
38 | Nome do Estudante...: ${this.nomeEstudante}.
39 | Idade do Estudante...: ${this.idade}`;
40 | }
41 | }
42 |
43 | const estudante_02 = new Estudante_02(98765, 'Glaucia Lemos', 35);
44 | console.log(estudante_02.retornarDadosEstudante());
45 |
46 | // ==> Exemplo 03 - Modificador: protected
47 | class Estudante_03 {
48 | codigoEstudante: number;
49 | protected nomeEstudante: string;
50 |
51 | constructor(codigoEstudante: number, nomeEstudante: string) {
52 | this.codigoEstudante = codigoEstudante;
53 | this.nomeEstudante = nomeEstudante;
54 | }
55 | }
56 |
57 | class Pessoa extends Estudante_03 {
58 | private curso: string;
59 |
60 | constructor(codigoEstudante: number, nomeEstudante: string, curso: string) {
61 | super(codigoEstudante, nomeEstudante);
62 | this.curso = curso;
63 | }
64 |
65 | retornarDados() {
66 | return `Código do Aluno: ${this.codigoEstudante}.
67 | Nome do Estudante: ${this.nomeEstudante}.
68 | Matéria: ${this.curso}`;
69 | }
70 | }
71 |
72 | const estudante_03 = new Pessoa(783212, 'Glaucia Lemos', 'Matemática');
73 | console.log(estudante_03.retornarDados());
74 |
--------------------------------------------------------------------------------
/modulo-05/aula-55-access-modifier-readonly/readonlyModifier.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable prettier/prettier */
2 | /**
3 | * arquivo: readonlyModifier.ts
4 | * descrição: arquivo responsável por ensinar como usar o 'Modificadores de
5 | * Acesso Readonly' no Typescript
6 | * data: 13/07/2022
7 | * author: Glaucia Lemos
8 | */
9 |
10 | export { };
11 |
12 | // ==> Exemplo 01
13 | class Funcionario {
14 | readonly dataNascimento: Date;
15 |
16 | constructor(dataNascimento: Date) {
17 | this.dataNascimento = dataNascimento;
18 | }
19 | }
20 |
21 | const funcionario = new Funcionario(new Date(1986, 10, 24));
22 | // funcionario.dataNascimento = new Date(1986, 10, 24);
23 |
24 | // ==> Exemplo 02
25 |
26 | class Funcionario_01 {
27 | constructor(readonly dataNascimento: Date) {
28 | this.dataNascimento = dataNascimento;
29 | }
30 | }
31 |
32 | // ==> Exemplo 03
33 |
34 | class Funcionario_03 {
35 | nome: string;
36 | readonly codigoFuncionario: number;
37 |
38 | constructor(nome: string, codigo: number) {
39 | this.codigoFuncionario = codigo;
40 | this.nome = nome;
41 | }
42 | }
43 |
44 | const func = new Funcionario_03('Glaucia', 112233);
45 | func.nome = 'Glaucia Lemos';
46 | // func.codigoFuncionario = 113344;
47 |
48 | console.log(func);
49 |
50 | // ==> Exemplo 04 - Interface
51 |
52 | interface IFuncionario {
53 | codigoFuncionario: number;
54 | nomeEmpregado: string;
55 | }
56 |
57 | const funcionario_01: Readonly = {
58 | codigoFuncionario: 506699,
59 | nomeEmpregado: 'Jurema',
60 | };
61 |
62 | // funcionario_01.codigoFuncionario = 887653;
63 | // funcionario_01.nomeEmpregado = 'Lemos';
64 |
65 | const funcionario_02: IFuncionario = {
66 | codigoFuncionario: 506699,
67 | nomeEmpregado: 'Jurema',
68 | };
69 |
70 | funcionario_02.codigoFuncionario = 887653;
71 | funcionario_02.nomeEmpregado = 'Lemos';
72 |
--------------------------------------------------------------------------------
/modulo-05/aula-57-getters-setters/gettersSetters.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable prettier/prettier */
2 | /**
3 | * arquivo: gettersSetters.ts
4 | * descrição: arquivo responsável por ensinar como usar getters e
5 | * setters no TypeScript
6 | * data: 01/08/2022
7 | * author: Glaucia Lemos
8 | */
9 |
10 | export { };
11 |
12 | //==>Exemplo 01: Get
13 | class Quadrado {
14 | private _largura = 6;
15 | private _altura = 12;
16 |
17 | get calcularQuadrado() {
18 | return this._altura * this._largura;
19 | }
20 | }
21 |
22 | console.log(new Quadrado().calcularQuadrado);
23 |
24 |
25 | //==> Exemplo 02: Set
26 | class Pessoa {
27 | nome: string;
28 |
29 | retornarNomePessoa(setNomePessoa: string) {
30 | this.nome = setNomePessoa;
31 | }
32 | }
33 |
34 | const pessoa = new Pessoa();
35 | pessoa.retornarNomePessoa('Glaucia Lemos');
36 | console.log('Meu nome é...: ', pessoa.nome);
37 |
38 | //==>Exemplo 03: Get [explicação mais densa]
39 | class Estudante {
40 | private _nome = 'Glaucia Lemos';
41 | private _semestre: number;
42 | private _curso: string;
43 |
44 | public get nomeEstudante() {
45 | return this._nome;
46 | }
47 | }
48 |
49 | const estudante = new Estudante();
50 | const resultado = estudante.nomeEstudante;
51 | console.log(resultado);
52 |
53 | //==>Exemplo 04: Set/Get [explicação mais densa]
54 | class Estudante_01 {
55 | nome: string;
56 | semestre: number;
57 | curso: string;
58 |
59 | constructor(nomeEstudante: string, semestreEstudante: number, cursoEstudante: string) {
60 | this.nome = nomeEstudante;
61 | this.semestre = semestreEstudante;
62 | this.curso = cursoEstudante;
63 | }
64 |
65 | public get cursos() {
66 | return this.curso;
67 | }
68 |
69 | public set cursos(setCurso: string) {
70 | this.curso = setCurso;
71 | }
72 | }
73 |
74 | const estudante_01 = new Estudante_01('Glaucia Lemos', 5, 'Sistema da Informação');
75 | console.log(estudante_01);
76 |
77 | // Setter call
78 | estudante_01.cursos = 'Análise e Desenvolvimento de Sistemas';
79 |
80 | // Getter call
81 | console.log('Curso atualizado...:', estudante_01.cursos)
82 |
--------------------------------------------------------------------------------
/modulo-05/aula-59-inheritance/inheritance.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable prettier/prettier */
2 | /**
3 | * arquivo: inheritance.ts
4 | * descrição: arquivo responsável por ensinar como heranças no TypeScript
5 | * data: 05/08/2022
6 | * author: Glaucia Lemos
7 | */
8 |
9 | export { };
10 |
11 | // ==> Exemplo 01
12 | class Animal {
13 | mover(distancia = 0) {
14 | console.log(`Animal se moveu...: ${distancia} metros.`);
15 | }
16 | }
17 |
18 | class Cachorro extends Animal {
19 | latir() {
20 | console.log('Au, Au!');
21 | }
22 | }
23 |
24 | const cachorro = new Cachorro();
25 | cachorro.latir();
26 | cachorro.mover(10);
27 | cachorro.latir();
28 |
29 | // ==> Exemplo 02
30 | class Pessoa {
31 | constructor(private nome: string, private sobrenome: string) {
32 | this.nome = nome;
33 | this.sobrenome = sobrenome;
34 | }
35 |
36 | retornarNomeCompleto(): string {
37 | return `${this.nome} ${this.sobrenome}`;
38 | }
39 |
40 | apresentarPessoa(): string {
41 | return `Meu nome é ${this.nome} ${this.sobrenome}.`;
42 | }
43 | }
44 |
45 | class Funcionario extends Pessoa {
46 | constructor(nome: string, sobrenome: string, private funcao: string) {
47 | super(nome, sobrenome);
48 | }
49 |
50 | retornarNome_02(): string {
51 | return super.apresentarPessoa() + `E, sou ${this.funcao}`;
52 | }
53 | }
54 |
55 | const funcionario = new Funcionario('Glaucia', 'Lemos', 'Developer Advocate');
56 | console.log(funcionario.apresentarPessoa());
57 | console.log(funcionario.retornarNomeCompleto());
58 | console.log(funcionario.retornarNome_02());
59 |
60 |
--------------------------------------------------------------------------------
/modulo-05/aula-61-static-members/static.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: static.ts
3 | * descrição: arquivo responsável por ensinar uso de métodos e propriedades
4 | * estáticos no TypeScript
5 | * data: 16/08/2022
6 | * author: Glaucia Lemos
7 | */
8 |
9 | // eslint-disable-next-line prettier/prettier
10 | export { };
11 |
12 | // ==> Exemplo 01: Propriedades Estáticas
13 | class Funcionario {
14 | static contratacoes = 0;
15 |
16 | constructor(
17 | private nome: string,
18 | private sobrenome: string,
19 | private titulo: string,
20 | ) {
21 | // nome classe + nome propriedade
22 | Funcionario.contratacoes++;
23 | }
24 | }
25 |
26 | const funcionario_01 = new Funcionario('Glaucia', 'Lemos', 'Developer');
27 | const funcionario_02 = new Funcionario('Jurema', 'Lemos', 'Professora');
28 | console.log(Funcionario.contratacoes);
29 |
30 |
31 | // ==> Exemplo 02 - Métodos estáticos
32 | class Funcionario_01 {
33 | private static contratacoes = 0;
34 |
35 | constructor(
36 | private nome: string,
37 | private sobrenome: string,
38 | private titulo: string,
39 | ) {
40 | Funcionario_01.contratacoes++;
41 | }
42 |
43 | public static retornarContratacoes() {
44 | return Funcionario_01.contratacoes;
45 | }
46 | }
47 |
48 | const funcionario_01 = new Funcionario_01(
49 | 'Glaucia',
50 | 'Lemos',
51 | 'Developer Advocate',
52 | );
53 |
54 | const funcionario_02 = new Funcionario_01('Jurema', 'Lemos', 'Professora');
55 |
56 | console.log(Funcionario_01.retornarContratacoes());
57 |
58 | // ==> Exemplo 03 - Propriedades estáticas
59 | type Raca = 'Spitz Alemão' | 'Buldogue' | 'Pug' | 'Yorkshire' | 'Poodle';
60 |
61 | class Cachorro {
62 | public nome: string;
63 | public idade: number;
64 | public racas: Raca[];
65 | public static QTD_CACHORRO_VENDIDO = 0;
66 |
67 | constructor(nome: string, idade: number, racas: Raca[]) {
68 | this.nome = nome;
69 | this.idade = idade;
70 | this.racas = racas;
71 |
72 | Cachorro.QTD_CACHORRO_VENDIDO++;
73 | console.log(Cachorro.QTD_CACHORRO_VENDIDO);
74 | }
75 |
76 | public exibirInformacao(): void {
77 | console.log(`O cachorro ${this.nome} tem ${this.idade}.`);
78 | }
79 | }
80 |
81 | const cachorro_01 = new Cachorro('Pipoca', 4, ['Spitz Alemão']);
82 | const cachorro_02 = new Cachorro('Farofa', 6, ['Yorkshire']);
83 |
--------------------------------------------------------------------------------
/modulo-05/aula-63-abstract-classes/abstractClasses.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: abastractClasses.ts
3 | * descrição: arquivo responsável por ensinar uso de classes abstratas no TypeScript
4 | * data: 11/18/2022
5 | * author: Glaucia Lemos
6 | */
7 |
8 | export { };
9 |
10 | abstract class Funcionario {
11 | constructor(private nome: string, private sobrenome: string) { }
12 |
13 | abstract retornarSalario(): number;
14 | get retornarNomeCompleto(): string {
15 | return `${this.nome} ${this.sobrenome}`;
16 | }
17 |
18 | emitirContraCheque(): string {
19 | return `${this.retornarNomeCompleto} - Salário: ${this.retornarSalario()}`;
20 | }
21 | }
22 |
23 | class FuncionarioCLT extends Funcionario {
24 | constructor(nome: string, sobrenome: string, private salario: number) {
25 | super(nome, sobrenome);
26 | }
27 |
28 | retornarSalario(): number {
29 | return this.salario;
30 | }
31 | }
32 |
33 | class FuncionarioPJ extends Funcionario {
34 | constructor(nome: string, sobrenome: string, private valorHora: number, private horasTrabalhadas: number) {
35 | super(nome, sobrenome);
36 | }
37 |
38 | retornarSalario(): number {
39 | return this.valorHora * this.horasTrabalhadas;
40 | }
41 | }
42 |
43 | const glaucia = new FuncionarioCLT('Glaucia', 'Lemos', 18000);
44 | const joao = new FuncionarioPJ('João', 'Silva', 150, 160);
45 |
46 | console.log(glaucia.emitirContraCheque());
47 | console.log(joao.emitirContraCheque());
48 |
49 | // const funcionario = new Funcionario('Glaucia', 'Lemos');
--------------------------------------------------------------------------------
/modulo-06/README.md:
--------------------------------------------------------------------------------
1 | # Módulo 6: Enum
2 |
3 | Aqui vocês encontrarão todos os vídeos e os exemplos desenvolvidos durante o módulo 06.
4 |
5 | ## 💻 Série de Vídeos
6 |
7 | | Vídeo Aula | Descrição |
8 | | -------------------------------------------- | --------------------------------------- |
9 | | **[Vídeo 64](https://youtu.be/kr-7yJxMfuU)** | Vídeo 64 - Introdução à Interfaces |
10 | | **[Vídeo 65](https://youtu.be/gEmE6EnnMN4)** | Vídeo 65 - Demo: Interfaces |
11 | | **[Vídeo 66](https://youtu.be/Eul-SGHaziA)** | Vídeo 66 - Extensão de Interfaces |
12 | | **[Vídeo 67](https://youtu.be/x0KYhX22DJ8)** | Vídeo 67 - Demo: Extensão de Interfaces |
13 |
14 |
--------------------------------------------------------------------------------
/modulo-06/aula-65-interfaces/interfaces.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: interfaces.ts
3 | * descrição: arquivo responsável por ensinar uso de 'Interfaces' em TypeScript
4 | * data: 11/18/2022
5 | * author: Glaucia Lemos
6 | */
7 |
8 | export { };
9 |
10 | // ==> Exemplo 01: Interface Simples
11 |
12 | interface Pessoa {
13 | nome: string;
14 | sobrenome: string;
15 | idade: number;
16 | }
17 |
18 | function exibirNome(pessoa: Pessoa) {
19 | return `
20 | Nome...: ${pessoa.nome}
21 | Sobrenome...: ${pessoa.sobrenome}
22 | Idade...: ${pessoa.idade}
23 | `;
24 | }
25 |
26 | const glaucia = {
27 | nome: 'Glaucia',
28 | sobrenome: 'Lemos',
29 | idade: 36,
30 | }
31 |
32 | console.log(exibirNome(glaucia));
33 |
34 | // ==> Exemplo 02: Interface com Propriedades Opcionais
35 |
36 | interface Livro {
37 | titulo: string;
38 | autor: string;
39 | paginas?: number; // ==> Propriedade Opcional
40 | }
41 |
42 | const livro: Livro = {
43 | titulo: 'Clean Code',
44 | autor: 'Robert C. Martin',
45 | }
46 |
47 | console.log(livro);
48 |
49 | // ==> Exemplo 03: Interface com Propriedades de Somente Leitura e Opcionais
50 |
51 | interface Carro {
52 | readonly modelo: string;
53 | ano: number;
54 | valor?: number;
55 | }
56 |
57 | const carro: Carro = {
58 | modelo: 'Fusca',
59 | ano: 1969,
60 | }
61 |
62 | // carro.modelo = 'Fusca 2.0';
63 |
64 | console.log(carro);
65 |
66 | // ==> Exemplo 04: Interface com implements Class
67 |
68 | interface Animal {
69 | nome: string;
70 | idade: number;
71 | estaVivo: boolean;
72 | comer(tipoComida: string): void;
73 | }
74 |
75 | class Gato implements Animal {
76 | nome: string;
77 | idade: number;
78 | estaVivo: boolean;
79 |
80 | constructor(nome: string, idade: number, estaVivo: boolean) {
81 | this.nome = nome;
82 | this.idade = idade;
83 | this.estaVivo = estaVivo;
84 | }
85 |
86 | comer(tipoComida: string): void {
87 | console.log(`O gato ${this.nome} está comendo ${tipoComida}`);
88 | }
89 | }
90 |
91 | const gato = new Gato('Totó', 10, true);
92 | console.log(gato);
93 | gato.comer('Ração');
94 |
95 | // ==> Exemplo 05: Interfaces vs Alias Type
96 |
97 | interface Pessoa_02 {
98 | nome: string;
99 | sobrenome: string;
100 | idade: number;
101 | }
102 |
103 | type Pessoa_03 = {
104 | nome: string;
105 | sobrenome: string;
106 | idade: number;
107 | }
108 |
109 |
--------------------------------------------------------------------------------
/modulo-06/aula-67-extends-interfaces/extendsInterfaces.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: extendsInterfaces.ts
3 | * descrição: arquivo responsável por ensinar uso de 'extends' e 'implements' em TypeScript
4 | * data: 12/12/2022
5 | * author: Glaucia Lemos
6 | */
7 |
8 | exports = {};
9 | // ==> Exemplo 01 - Interfaces com extends
10 | interface Animal_01 {
11 | nome: string;
12 | idade: number;
13 | porte: string;
14 | }
15 |
16 | interface Cachorro_01 extends Animal_01 {
17 | raca: string;
18 | }
19 |
20 | const cachorro: Cachorro_01 = {
21 | nome: 'Prince',
22 | idade: 2,
23 | porte: 'Médio',
24 | raca: 'Spiz Alemao',
25 | };
26 |
27 | console.log(cachorro);
28 |
29 | // ==> Exemplo 02 - Extensão de Múltiplas Interfaces
30 |
31 | interface Cachorro {
32 | nome: string;
33 | }
34 |
35 | interface Gato {
36 | nome: string;
37 | }
38 |
39 | interface Animal extends Cachorro, Gato {
40 | idade: number;
41 | }
42 |
43 | const animal: Animal = {
44 | nome: 'Farofa',
45 | idade: 5,
46 | };
47 |
48 | console.log(animal);
49 |
50 | // ==> Exemplo 03 - Uso do Omit
51 |
52 | interface Funcionario {
53 | id: number;
54 | nome: string;
55 | salario: number;
56 | }
57 |
58 | interface Desenvolvedor extends Omit {
59 | id: string;
60 | salario: string;
61 | linguageProgramacao: string;
62 | }
63 |
64 | const desenvolvedor: Desenvolvedor = {
65 | id: 'js-123',
66 | nome: 'Glaucia Lemos',
67 | salario: '10k',
68 | linguageProgramacao: 'JavaScript',
69 | }
70 |
71 | console.log(desenvolvedor)
72 |
73 | // Exemplo 04 - Uso do pipe
74 |
75 | /*interface Funcionario {
76 | id: number | string;
77 | nome: string;
78 | salario: number | string;
79 | }
80 |
81 | interface Desenvolvedor extends Funcionario {
82 | id: string;
83 | salario: string;
84 | linguageProgramacao: string;
85 | }
86 |
87 | const desenvolvedor: Desenvolvedor = {
88 | id: 'js-123',
89 | nome: 'Glaucia Lemos',
90 | salario: '10k',
91 | linguageProgramacao: 'JavaScript',
92 | }
93 |
94 | console.log(desenvolvedor)*/
--------------------------------------------------------------------------------
/modulo-07/README.md:
--------------------------------------------------------------------------------
1 | # Módulo 7: Tipos Avançados & Novos Operadores
2 |
3 | Aqui vocês encontrarão todos os vídeos e os exemplos desenvolvidos durante o módulo 07.
4 |
5 | ## 💻 Série de Vídeos
6 |
7 | | Vídeo Aula | Descrição |
8 | | -------------------------------------------- | ----------------------------------- |
9 | | **[Vídeo 68](https://youtu.be/2hE57wR86YY)** | Vídeo 68 - Intersection Types |
10 | | **[Vídeo 69](https://youtu.be/LvVWaHk3l0I)** | Vídeo 69 - Demo: Intersection Types |
11 | | **[Vídeo 70](https://youtu.be/DNmCS4PT9bc)** | Vídeo 70 - Type Guards |
12 | | **[Vídeo 71](https://youtu.be/83eUc_Qzvxk)** | Vídeo 71 - Demo: Type Guards |
13 | | **[Vídeo 72](https://youtu.be/eAjmQ_8fKwY)** | Vídeo 72 - Type Casting |
14 | | **[Vídeo 73](https://youtu.be/UlTeD4l6OmQ)** | Vídeo 73 - Demo: Type Casting |
15 | | **[Vídeo 74](https://youtu.be/A5SOxUAOCIQ)** | Vídeo 74 - Type Assertions |
16 | | **[Vídeo 75](https://youtu.be/B0ByaF7x184)** | Vídeo 75 - Demo: Type Assertions |
17 | | **[Vídeo 76](https://youtu.be/nBhTRUHMgng)** | Vídeo 76 - Conditional Types |
18 | | **[Vídeo 77](https://youtu.be/vCNV9gu75Ic)** | Vídeo 77 - Demo: Conditional Types |
19 | | **[Vídeo 78](https://youtu.be/eztQedVNdY0)** | Vídeo 78 - Mapped Types |
20 | | **[Vídeo 79](https://youtu.be/ih1t6eKSh24)** | Vídeo 79 - Demo: Mapped Types |
21 | | **[Vídeo 80](https://youtu.be/nSKE7Vhh11A)** | Vídeo 80 - Satisfies Operator |
22 | | **[Vídeo 81](https://youtu.be/wRdvq7UodjQ)** | Vídeo 81 - Demo: Satisfies Operator |
23 |
--------------------------------------------------------------------------------
/modulo-07/aula-69-intersection-types/intersectionTypes.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: intersectionTypes.ts
3 | * descrição: arquivo responsável por ensinar uso de 'Intersection Types' em TypeScript
4 | * data: 12/22/2022
5 | * author: Glaucia Lemos
6 | */
7 |
8 | export = {};
9 |
10 | // ==> Exemplo 01 - Intersection Types:
11 |
12 | interface DadosBancarios {
13 | conta: number;
14 | agencia: number;
15 | banco: string;
16 | }
17 |
18 | interface Cliente {
19 | nome: string;
20 | email: string;
21 | }
22 |
23 | interface DadosPessoaFisica {
24 | cpf: number;
25 | }
26 |
27 | type DadosCliente = DadosBancarios & Cliente & DadosPessoaFisica;
28 |
29 | const dadosCliente: DadosCliente = {
30 | conta: 123456,
31 | agencia: 123,
32 | banco: "Banco do Brasil",
33 | nome: "Glaucia Lemos",
34 | email: "glaucia@email.com",
35 | cpf: 123456789,
36 | }
37 |
38 | console.log(dadosCliente)
39 |
40 | // ==> Exemplo 02 - Intersection Types:
41 |
42 | interface IEndereco {
43 | rua: string;
44 | bairro: string;
45 | cidade: string;
46 | }
47 |
48 | interface IPessoa {
49 | nome: string;
50 | idade: number;
51 | profissao: string;
52 | }
53 |
54 | type IEnderecoPessoa = IEndereco & IPessoa;
55 |
56 | const enderecoPessoa: IEnderecoPessoa = {
57 | nome: 'Glaucia Lemos',
58 | idade: 36,
59 | profissao: 'Software Engineer',
60 | rua: 'Rua das Tulipas',
61 | bairro: 'Bairro das Tulipas',
62 | cidade: 'Rio de Janeiro',
63 | };
64 |
65 | console.log(enderecoPessoa);
66 |
--------------------------------------------------------------------------------
/modulo-07/aula-71-type-guards/typeGuards.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: typeGuards.ts
3 | * descrição: arquivo responsável por ensinar o uso de Type Guards em TypeScript
4 | * data: 01/12/2022
5 | * author: Glaucia Lemos
6 | */
7 |
8 | exports = {};
9 |
10 | // ==> Exemplo 01 - Type Guards: typeof
11 | type alfanumerico = string | number;
12 |
13 | function exibirTipo(a: alfanumerico, b: alfanumerico) {
14 | if (typeof a === 'number' && typeof b === 'number') {
15 | return a + b;
16 | }
17 |
18 | if (typeof a === 'string' && typeof b === 'string') {
19 | return a.concat(b);
20 | }
21 |
22 | throw new Error('Argumentos inválidos! Ambos os argumentos devem ser númericos ou string.');
23 | }
24 |
25 | console.log(exibirTipo('Glaucia', '2'));
26 | console.log(exibirTipo(5, 5));
27 | // console.log(exibirTipo('Lemos', 5));
28 |
29 | // ==> Exemplo 02 - Type Guards: instanceof
30 | class Carro {
31 | nome: string;
32 | marca: string;
33 |
34 | constructor(nome: string, marca: string) {
35 | this.nome = nome;
36 | this.marca = marca;
37 | }
38 | }
39 |
40 | class Moto {
41 | nome: string;
42 | ano: number;
43 |
44 | constructor(nome: string, ano: number) {
45 | this.nome = nome;
46 | this.ano = ano;
47 | }
48 | }
49 |
50 | function detalhesVeiculo(veiculo: Carro | Moto) {
51 | if (veiculo instanceof Carro) {
52 | return `O nome do carro é: ${veiculo.nome} e a marca é: ${veiculo.marca}`;
53 | } else if (veiculo instanceof Moto) {
54 | return `O nome da moto é: ${veiculo.nome} e o ano é: ${veiculo.ano}`;
55 | }
56 | }
57 |
58 | const carro = new Carro('Gol', 'Volkswagen');
59 | console.log(detalhesVeiculo(carro));
60 |
61 | const moto = new Moto('CBR', 2020);
62 | console.log(detalhesVeiculo(moto));
63 |
64 |
65 | // ==> Exemplo 03 - Type Guards: in
66 | interface Animal_05 {
67 | grupo: string;
68 | }
69 |
70 | class Peixe implements Animal_05 {
71 | grupo: string;
72 | corPeixe: string;
73 |
74 | constructor(grupo: string, corPeixe: string) {
75 | this.grupo = grupo;
76 | this.corPeixe = corPeixe;
77 | }
78 | }
79 |
80 | class Passaro implements Animal_05 {
81 | grupo: string;
82 | corPena: string;
83 |
84 | constructor(grupo: string, corPena: string) {
85 | this.grupo = grupo;
86 | this.corPena = corPena;
87 | }
88 | }
89 |
90 | function nadar(grupo: string) {
91 | console.log(`O ${grupo} está nadando!`);
92 | }
93 |
94 | function voar(grupo: string) {
95 | console.log(`O ${grupo} está voando!`);
96 | }
97 |
98 | function mover(animal: Animal_05) {
99 | if ('corPeixe' in animal) {
100 | nadar((animal as Peixe).grupo);
101 | } else if ('corPena' in animal) {
102 | voar((animal as Passaro).grupo);
103 | }
104 | }
105 |
106 | mover(new Passaro('Pássaro', 'Vermelho'));
107 | mover(new Peixe('Peixe', 'Azul'));
--------------------------------------------------------------------------------
/modulo-07/aula-73-type-casting/typeCasting.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: typeCasting.ts
3 | * descrição: arquivo responsável por ensinar uso de 'Type Casting' em TypeScript
4 | * data: 01/26/2023
5 | * author: Glaucia Lemos
6 | */
7 |
8 | export { };
9 |
10 | // ==> Exemplo 01 - Type Casting: 'as'
11 |
12 | const nome: unknown = 'Glaucia Lemos';
13 | console.log((nome as string).toLowerCase());
14 |
15 | // ==> Exemplo 02 - Type Casting: '<>'
16 | const carro = 'Corolla';
17 |
18 | const tamanhoString: number = (carro).length;
19 |
20 | console.log('O tamanho da string é...: ', tamanhoString);
21 |
22 |
23 |
--------------------------------------------------------------------------------
/modulo-07/aula-75-type-assertion/typeAssertions.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: typeAssertion.ts
3 | * descrição: arquivo responsável por ensinar uso de 'Type Assertion' em TypeScript
4 | * data: 02/21/2023
5 | * author: Glaucia Lemos
6 | */
7 |
8 | export { };
9 |
10 | // ==> Exemplo 01 - Type Assertions (as / < >)
11 |
12 | function exibirPrecoFinal(preco: number, desconto: number, formato: boolean): number | string {
13 | const precoComDesconto = preco * (1 - desconto);
14 |
15 | return formato ? `R$ ${precoComDesconto}` : precoComDesconto;
16 | }
17 |
18 | // const descontoFinal = exibirPrecoFinal(100, 0.05, true) as string;
19 | const descontoFinal = exibirPrecoFinal(100, 0.05, false);
20 | console.log(descontoFinal);
21 |
22 |
23 | // ==> Exemplo 02 - Type Assertions
24 |
25 | /*type Humano = {
26 | nome: string;
27 | idade: number;
28 | idioma: string;
29 | }
30 |
31 | const humano = {
32 | idade: 36,
33 | idioma: 'Português'
34 | };
35 |
36 | const humano_02 = humano as Humano;
37 | console.log(humano_02.nome.toUpperCase());*/
38 |
39 | /*type Humano = {
40 | nome: string;
41 | idade: number;
42 | idioma: string;
43 | }
44 |
45 | const humano = {
46 | idade: 36,
47 | idioma: 'Português'
48 | };
49 |
50 | const humano_02: Humano = humano;
51 | console.log(humano_02.nome.toUpperCase());*/
--------------------------------------------------------------------------------
/modulo-07/aula-77-conditional-types/conditionalTypes.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: typeAssertion.ts
3 | * descrição: arquivo responsável por ensinar uso de 'Conditional Types' em TypeScript
4 | * data: 03/01/2023
5 | * author: Glaucia Lemos
6 | */
7 |
8 | export = {};
9 |
10 |
11 | // ==> Exemplo 01 - Conditional Types
12 | type Pessoa = {
13 | nome: string;
14 | idade: number;
15 | endereco: string;
16 | };
17 |
18 | type Empresa = {
19 | nome: string;
20 | cnpj: number;
21 | };
22 |
23 | type EnderecoPessoa = {
24 | enderecoSecundario: string;
25 | cidade: string;
26 | pais: string;
27 | };
28 |
29 | type EnderecoEmpresa = {
30 | localizacao: 'rua' | 'avenida' | 'praça';
31 | };
32 |
33 | type EnderecoFinal = T extends { endereco: string } ? EnderecoPessoa : EnderecoEmpresa;
34 |
35 | const enderecoPessoa: EnderecoFinal = {
36 | enderecoSecundario: 'Rua 2',
37 | cidade: 'São Paulo',
38 | pais: 'Brasil',
39 | };
40 |
41 | const enderecoEmpresa: EnderecoFinal = {
42 | localizacao: 'rua',
43 | };
44 |
45 | console.log(enderecoPessoa);
46 | console.log(enderecoEmpresa);
47 |
48 | // ==> Exemplo 02 - Conditional Types ()
49 |
50 | type FormatoArquivos = 'png' | 'jpg' | 'gif' | 'svg' | 'mp4' | 'mp3';
51 |
52 | type FiltrarArquivoAudio = T extends 'mp4' | 'mp3' ? T : never;
53 |
54 | type ArquivoAudio = FiltrarArquivoAudio;
55 |
56 | const arquivoAudio: ArquivoAudio = 'mp4';
57 |
58 | console.log(arquivoAudio);
59 |
60 |
--------------------------------------------------------------------------------
/modulo-07/aula-79-mapped-types/mappedTypes.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: mappedTypes.ts
3 | * descrição: arquivo responsável por ensinar uso de 'Mapped Types' em TypeScript
4 | * data: 03/04/2023
5 | * author: Glaucia Lemos
6 | */
7 |
8 | export { };
9 |
10 |
11 | // ==> Exemplo 01: Mapped Types
12 |
13 | type Usuario = {
14 | nome: string;
15 | endereco: string;
16 | telefone: string;
17 | idade: number;
18 | };
19 |
20 | type UsuarioOpcional = {
21 | nome?: string;
22 | endereco?: string;
23 | telefone?: string;
24 | idade?: number;
25 | };
26 |
27 | type UsusarioSomenteLeitura = {
28 | readonly nome: string;
29 | readonly endereco: string;
30 | readonly telefone: string;
31 | readonly idade: number;
32 | };
33 |
34 | // { [P in K]: T }
35 |
36 | type UsuarioMappedType = {
37 | [P in keyof Usuario]?: Usuario[P]; // for in
38 | };
39 |
40 | // 'nome' | 'endereco' | 'telefone' | 'idade'
41 |
42 | const usuarioMapped: UsuarioMappedType = {
43 | nome: 'Glaucia Lemos',
44 | endereco: 'Rua 01, 123',
45 | }
46 |
47 | console.log(usuarioMapped);
48 |
49 | // ==> Exemplo 02: Outros Tipos Avançados
50 |
51 | interface Livro {
52 | titulo: string;
53 | autor: string | null;
54 | preco: number;
55 | numeroPaginas: number;
56 | }
57 |
58 | type Artigo = Omit;
59 |
60 | type LivroModelo = Readonly;
61 |
62 | const livro: LivroModelo = {
63 | autor: 'Boris Cherny',
64 | numeroPaginas: 324,
65 | preco: 19.99,
66 | titulo: 'Programming Typescript: Making Your JavaScript Applications Scale'
67 | }
68 |
69 | // livro.autor = "Glaucia Lemos"
--------------------------------------------------------------------------------
/modulo-07/aula-81-satisfies-operator/satisfiesOperator.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: satisfiesOperator.ts
3 | * descrição: arquivo responsável por ensinar uso do 'satisfies' operator
4 | * data: 23/03/2023
5 | * author: Glaucia Lemos
6 | */
7 |
8 | // ==> Exemplo 01: Satisfies Operator
9 |
10 | export { };
11 |
12 | type Cidade = NomeCidade | CidadeCoordenadas;
13 |
14 | type NomeCidade = "São Paulo" | "Rio de Janeiro" | "Salvador" | "Belo Horizonte";
15 |
16 | type CidadeCoordenadas = {
17 | x: number;
18 | y: number;
19 | };
20 |
21 | type Pessoa = {
22 | localNascimento: Cidade;
23 | residenciaAtual: Cidade;
24 | };
25 |
26 | const pessoa = {
27 | localNascimento: "Rio de Janeiro",
28 | residenciaAtual: { x: 10, y: 20 },
29 | } satisfies Pessoa
30 |
31 | console.log(pessoa.localNascimento.toUpperCase());
32 |
33 | // ==> Exemplo 02: Satisfies Operator
34 |
35 | type Connection = {};
36 |
37 | declare function createConnection(
38 | host: string,
39 | port: string,
40 | reconnect: boolean,
41 | poolsize: number
42 | ): Connection;
43 |
44 | type Configuration = {
45 | host: string;
46 | port: string | number;
47 | tryReconnect: boolean | (() => boolean);
48 | poolSize?: number;
49 | };
50 |
51 | const config = {
52 | host: "localhost",
53 | port: 3306,
54 | tryReconnect: () => true,
55 | poolSize: 10,
56 | } satisfies Configuration;
57 |
58 | function connect() {
59 | let { host, port, tryReconnect } = config;
60 |
61 | createConnection(host, `${port}`, tryReconnect(), 10);
62 | }
--------------------------------------------------------------------------------
/modulo-08/README.md:
--------------------------------------------------------------------------------
1 | # Módulo 8: Generics
2 |
3 | Aqui vocês encontrarão todos os vídeos e os exemplos desenvolvidos durante o módulo 08.
4 |
5 | ## 💻 Série de Vídeos
6 |
7 | | Vídeo Aula | Descrição |
8 | | -------------------------------------------- | -------------------------------------- |
9 | | **[Vídeo 82](https://youtu.be/YES6DVWDrP8)** | Vídeo 82 - Introdução à Generecis |
10 | | **[Vídeo 83](https://youtu.be/3M33BurmTkI)** | Vídeo 83 - Demo: Introdução à Generics |
11 | | **[Vídeo 84](https://youtu.be/_aBEBpE633Y)** | Vídeo 84 - Generics Constraints |
12 | | **[Vídeo 85](https://youtu.be/pyEMVwE-vSI)** | Vídeo 85 - Demo: Generics Constraints |
13 | | **[Vídeo 86](https://youtu.be/qmjuwfIfB-I)** | Vídeo 86 - Generic Classes |
14 | | **[Vídeo 87](https://youtu.be/MyrmU5sAh8Y)** | Vídeo 87 - Demo: Generic Classes |
15 | | **[Vídeo 88](https://youtu.be/YNEuj-rfXnk)** | Vídeo 88 - Generics Interfaces |
16 | | **[Vídeo 89](https://youtu.be/sZWejDFIJVY)** | Vídeo 89 - Demo: Generics Interfaces |
--------------------------------------------------------------------------------
/modulo-08/aula-83-intro-generics/generics.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: generics.ts
3 | * descrição: arquivo responsável por ensinar uso do 'Generics' em TypeScript
4 | * data: 29/03/2023
5 | * author: Glaucia Lemos
6 | */
7 |
8 | export { };
9 |
10 | // ==> Exemplo 01: Generics
11 |
12 | function retornarElementosRandomicos(items: T[]): T {
13 | let itemRandomico = Math.floor(Math.random() * items.length);
14 | return items[itemRandomico];
15 | };
16 |
17 | let numeros = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10];
18 | let numerosRandomicos = retornarElementosRandomicos(numeros);
19 | console.log(numerosRandomicos);
20 |
21 | let estados = ['São Paulo', 'Rio de Janeiro', 'Minas Gerais', 'Paraná', 'Santa Catarina', 'Rio Grande do Sul'];
22 | let estadosRandomicos = retornarElementosRandomicos(estados);
23 | console.log(estadosRandomicos);
24 |
25 | // ==> Exemplo 02: Generics
26 |
27 | function exibirElementos(array: T[]): void {
28 | array.forEach((elemento) => {
29 | console.log(elemento);
30 | });
31 | };
32 |
33 | let number: number[] = [1, 2, 3, 4, 5];
34 | let states: string[] = ['São Paulo', 'Rio de Janeiro', 'Minas Gerais', 'Paraná', 'Santa Catarina', 'Rio Grande do Sul'];
35 |
36 | exibirElementos(number);
37 | exibirElementos(states);
--------------------------------------------------------------------------------
/modulo-08/aula-85-generics-contraints/genericsConstraints.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: genericsConstraints.ts
3 | * descrição: arquivo responsável por ensinar uso do 'Generics Constraints' em TypeScript
4 | * data: 05/04/2023
5 | * author: Glaucia Lemos
6 | */
7 |
8 | // ==> Exemplo 01 - Generics Constraints
9 |
10 | export { };
11 |
12 | interface Pessoa {
13 | nome: string;
14 | idade: number;
15 | }
16 |
17 | function obterPessoaIdadeMaiorQue(pessoas: T[], idade: number): T[] {
18 | return pessoas.filter(pessoa => pessoa.idade > idade);
19 | }
20 |
21 | const pessoas: Pessoa[] = [
22 | { nome: 'Glaucia', idade: 36 },
23 | { nome: 'João', idade: 20 },
24 | { nome: 'Angelica', idade: 30 },
25 | { nome: 'Maria', idade: 25 },
26 | { nome: 'José', idade: 18 },
27 | ];
28 |
29 | const pessoasComIdadeMaiorQue25 = obterPessoaIdadeMaiorQue(pessoas, 25);
30 |
31 | console.log(pessoasComIdadeMaiorQue25);
32 |
33 | // ==> Exemplo 02 - Generics Constraints
34 |
35 | function juntarObjetos(objeto1: U, objeto2: V) {
36 | return {
37 | ...objeto1,
38 | ...objeto2,
39 | }
40 | }
41 |
42 | const pessoa = juntarObjetos(
43 | { nome: 'Glaucia', },
44 | { idade: 36, }
45 | );
46 |
47 | console.log(pessoa);
48 |
49 | const pessoa2 = juntarObjetos(
50 | { nome: 'Glaucia' },
51 | 36
52 | );
53 |
54 | console.log(pessoa2);
55 |
56 | function juntarObjetos2(objeto1: U, objeto2: V) {
57 | return {
58 | ...objeto1,
59 | ...objeto2,
60 | }
61 | }
62 |
63 | const pessoa3 = juntarObjetos2(
64 | { nome: 'Glaucia' },
65 | { idade: 36 }
66 | );
67 |
68 | // ==> Exemplo 03 - Type parameter in generic constraints
69 |
70 | /*function prop(objeto: T, chave: K) {
71 | return objeto[chave];
72 | }*/
73 |
74 | function prop2(objeto: T, chave: K) {
75 | return objeto[chave];
76 | }
77 |
78 | const pessoa4 = prop2(
79 | { nome: 'Glaucia' }, 'nome'
80 | );
81 |
82 | console.log(pessoa4);
83 |
84 | /*const pessoa5 = prop2(
85 | { nome: 'Glaucia' }, 'idade'
86 | );
87 |
88 | console.log(pessoa5);*/
89 |
90 |
91 |
92 |
--------------------------------------------------------------------------------
/modulo-08/aula-87-generic-classes/genericClasses.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: genericClasses.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Generic Classes'
4 | * data: 13/04/2023
5 | * author: Glaucia Lemos
6 | */
7 |
8 | export { };
9 |
10 | // ==> Exemplo 01: Generic Classes
11 |
12 | class Box {
13 | private item: T;
14 |
15 | constructor(item: T) {
16 | this.item = item;
17 | }
18 |
19 | getItem() {
20 | return this.item;
21 | }
22 |
23 | setItem(item: T) {
24 | this.item = item;
25 | }
26 | }
27 |
28 | const boxString = new Box('Glaucia Lemos');
29 | const boxNumber = new Box(36);
30 |
31 | console.log(boxString.getItem()); // Saída: Glaucia Lemos
32 | console.log(boxNumber.getItem()); // Saída: 36
33 |
34 | // ==> Exemplo 02
35 | class Estudante {
36 | private id: T;
37 | private nome: U;
38 |
39 | setValor(id: T, nome: U): void {
40 | this.id = id;
41 | this.nome = nome;
42 | }
43 |
44 | retornarValor(): void {
45 | console.log(`Identificação do Estudante...: ${this.id}, Nome do Estudante...: ${this.nome}`);
46 | }
47 | }
48 |
49 | const estudante = new Estudante();
50 |
51 | estudante.setValor(101, "Glaucia Lemos");
52 | estudante.retornarValor();
53 |
54 | const estudanteSecundario = new Estudante();
55 |
56 | estudanteSecundario.setValor("201", "Jurema Lemos");
57 | estudanteSecundario.retornarValor();
58 |
59 |
--------------------------------------------------------------------------------
/modulo-08/aula-89-generics-interfaces/genericsInterfaces.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: genericsInterface.ts
3 | * descrição: arquivo responsável por ensinar sobre 'Generic Interfaces'
4 | * data: 19/04/2023
5 | * author: Glaucia Lemos
6 | */
7 |
8 | export { };
9 |
10 | // ==> Exemplo 01: Generic Interfaces
11 |
12 | interface Pair {
13 | first: T;
14 | second: U;
15 | }
16 |
17 | const myPair: Pair = {
18 | first: 36,
19 | second: 'Glaucia Lemos'
20 | };
21 |
22 | console.log(myPair); // Saída: { first: 36, second: 'Glaucia Lemos' }
23 |
24 | // ==> Exemplo 02: Generic Interfaces
25 |
26 | interface FetchResponse {
27 | data: T;
28 | status: number;
29 | statusText: string;
30 | headers: Record
31 | }
32 |
33 | async function fetchJson(url: string): Promise> {
34 | const response = await fetch(url);
35 | const headers: Record = {};
36 | response.headers.forEach((value, key) => {
37 | headers[key] = value;
38 | });
39 |
40 | const data = await response.json();
41 | return {
42 | data: data as T,
43 | status: response.status,
44 | statusText: response.statusText,
45 | headers
46 | };
47 | }
48 |
49 | (async () => {
50 | const response = await fetchJson<{ completed: boolean }>("https://jsonplaceholder.typicode.com/todos/1");
51 | console.log(response.data.completed)
52 | })();
--------------------------------------------------------------------------------
/modulo-09/README.md:
--------------------------------------------------------------------------------
1 | # Módulo 9: Módulos
2 |
3 | Aqui vocês encontrarão todos os vídeos e os exemplos desenvolvidos durante o módulo 09.
4 |
5 | ## 💻 Série de Vídeos
6 |
7 | | Vídeo Aula | Descrição |
8 | | -------------------------------------------- | ------------------------------- |
9 | | **[Vídeo 90](https://youtu.be/X2q064YSxn4)** | Vídeo 91 - Introdução à Modules |
10 | | **[Vídeo 91](https://youtu.be/5bUH11X4mCU)** | Vídeo 91 - Demo - Modules |
11 |
--------------------------------------------------------------------------------
/modulo-09/aula-91-intro-modules/main.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: main.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Modules'
4 | * data: 05/08/2023
5 | * author: Glaucia Lemos
6 | */
7 |
8 | import { somar, subtrair, multiplicar, dividir } from './math';
9 |
10 | console.log(somar(10, 20));
11 | console.log(subtrair(10, 20));
12 | console.log(multiplicar(10, 20));
13 | console.log(dividir(10, 20));
--------------------------------------------------------------------------------
/modulo-09/aula-91-intro-modules/math.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: math.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Modules'
4 | * data: 05/08/2023
5 | * author: Glaucia Lemos
6 | */
7 |
8 | // ==> Exemplo 01: Modules
9 |
10 | export function somar(x: number, y: number): number {
11 | return x + y;
12 | }
13 |
14 | export function subtrair(x: number, y: number): number {
15 | return x - y;
16 | }
17 |
18 | export function multiplicar(x: number, y: number): number {
19 | return x * y;
20 | }
21 |
22 | export function dividir(x: number, y: number): number {
23 | return x / y;
24 | }
25 |
26 |
27 |
28 |
29 |
--------------------------------------------------------------------------------
/modulo-09/aula-911-modules/main.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: main.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Modules'
4 | * data: 05/08/2023
5 | * author: Glaucia Lemos
6 | */
7 |
8 | import { EmailValidator, ZipCodeValidator } from "./validators";
9 |
10 | let email = 'glaucia.lemos@email.com';
11 | let validator = new EmailValidator();
12 | let result = validator.isValid(email);
13 |
14 | console.log(`O e-mail ${email} é válido? ${result}`);
15 |
16 | let validator2 = new ZipCodeValidator();
17 | let result2 = validator2.isValid('12345');
18 |
19 | console.log(`O CEP 12345 é válido? ${result2}`);
--------------------------------------------------------------------------------
/modulo-09/aula-911-modules/validators/email-validator.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: email-validator.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Modules'
4 | * data: 05/08/2023
5 | * author: Glaucia Lemos
6 | */
7 |
8 | //import { Validator as FormValidator } from "./validator";
9 | import { Validator } from "./validator";
10 |
11 | export default class EmailValidator implements Validator {
12 | isValid(s: string): boolean {
13 | const emailRegex = /\S+@\S+\.\S+/;
14 | return emailRegex.test(s);
15 | }
16 | }
--------------------------------------------------------------------------------
/modulo-09/aula-911-modules/validators/index.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: validators/index.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Modules'
4 | * data: 05/08/2023
5 | * author: Glaucia Lemos
6 | */
7 |
8 | import { Validator } from "./validator";
9 | import EmailValidator from "./email-validator";
10 | import { ZipCodeValidator } from "./zipcode-validator";
11 |
12 | export { Validator, EmailValidator, ZipCodeValidator };
--------------------------------------------------------------------------------
/modulo-09/aula-911-modules/validators/validator.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: validator.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Modules'
4 | * data: 05/08/2023
5 | * author: Glaucia Lemos
6 | */
7 |
8 | interface Validator {
9 | isValid(s: string): boolean;
10 | }
11 |
12 | export { Validator };
13 |
14 |
--------------------------------------------------------------------------------
/modulo-09/aula-911-modules/validators/zipcode-validator.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: zipcode-validator.ts
3 | * descrição: arquivo responsável por ensinar conceitos básicos sobre 'Modules'
4 | * data: 05/08/2023
5 | * author: Glaucia Lemos
6 | */
7 |
8 | import { Validator } from "./validator";
9 |
10 | class ZipCodeValidator implements Validator {
11 | isValid(s: string): boolean {
12 | const zipCodeRegex = /^[0-9]{5}(?:-[0-9]{3})?$/;
13 |
14 | return zipCodeRegex.test(s);
15 | }
16 | }
17 |
18 | export { ZipCodeValidator }
--------------------------------------------------------------------------------
/modulo-10/README.md:
--------------------------------------------------------------------------------
1 | # Módulo 10: TypeScript em Node.js
2 |
3 | Aqui vocês encontrarão todos os vídeos e os exemplos desenvolvidos durante o módulo 10.
4 |
5 | ## 💻 Série de Vídeos
6 |
7 | | Vídeo Aula | Descrição |
8 | | -------------------------------------------- | --------------------------------------------- |
9 | | **[Vídeo 92](https://youtu.be/bz2PeVJUgyM)** | Vídeo 92 - Projeto: TypeScript com Express.js |
10 |
--------------------------------------------------------------------------------
/modulo-10/ts-node-express/.gitignore:
--------------------------------------------------------------------------------
1 | node_modules
2 | .env
--------------------------------------------------------------------------------
/modulo-10/ts-node-express/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "ts-node-express",
3 | "version": "1.0.0",
4 | "description": "Aplicação exemplo de como criar uma aplicação Node.js com TypeScript e Express.js",
5 | "main": "dist/index.js",
6 | "scripts": {
7 | "build": "rimraf dist && tsc",
8 | "preserve": "npm run build",
9 | "serve": "cross-env NODE_ENV=development concurrently \"tsc --watch\" \"nodemon -q dist/index.js\"",
10 | "start": "cross-env NODE_ENV=production node dist/index.js",
11 | "test": "echo \"Error: no test specified\" && exit 1"
12 | },
13 | "keywords": [
14 | "typescript",
15 | "node",
16 | "express"
17 | ],
18 | "author": "Glaucia Lemos ",
19 | "license": "MIT",
20 | "dependencies": {
21 | "@types/express": "^4.17.17",
22 | "@types/node": "^20.2.1",
23 | "cross-env": "^7.0.3",
24 | "dotenv": "^16.0.3",
25 | "express": "^4.18.2",
26 | "helmet": "^7.0.0",
27 | "rimraf": "^5.0.1",
28 | "typescript": "^5.0.4"
29 | },
30 | "devDependencies": {
31 | "concurrently": "^8.0.1",
32 | "nodemon": "^2.0.22"
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/modulo-10/ts-node-express/src/index.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * arquivo: index.ts
3 | * descrição: arquivo responsável por fazer a chamada da api do Express.js
4 | * data: 05/18/2023
5 | * author: Glaucia Lemos
6 | */
7 |
8 | import express, { Express, Request, Response } from 'express';
9 | import helmet from 'helmet';
10 | import dotenv from 'dotenv';
11 |
12 | dotenv.config();
13 |
14 | const app: Express = express();
15 | const PORT = process.env.PORT || 3000;
16 |
17 | app.use(helmet());
18 | app.use(express.json());
19 | app.use(express.urlencoded({ extended: true }));
20 |
21 | app.get('/', (req: Request, res: Response) => {
22 | res.send('Hello, Developers! Sejam bem-vindos(as) ao TypeScript com Express.Js!
');
23 | });
24 |
25 | app.listen(PORT, () => console.log(`Servidor executando na porta ${PORT} `));
--------------------------------------------------------------------------------
/modulo-10/ts-node-express/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "target": "ES2020",
4 | "module": "CommonJS",
5 | "outDir": "dist",
6 | "esModuleInterop": true,
7 | "forceConsistentCasingInFileNames": true,
8 | "strict": true,
9 | "skipLibCheck": true
10 | }
11 | }
--------------------------------------------------------------------------------
/package-lock.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "curso-typescript-zero-to-hero",
3 | "version": "1.0.0",
4 | "lockfileVersion": 2,
5 | "requires": true,
6 | "packages": {
7 | "": {
8 | "name": "curso-typescript-zero-to-hero",
9 | "version": "1.0.0",
10 | "license": "ISC",
11 | "dependencies": {
12 | "@typescript-eslint/eslint-plugin": "^5.44.0",
13 | "@typescript-eslint/parser": "^5.44.0",
14 | "eslint-config-prettier": "^8.5.0",
15 | "eslint-plugin-prettier": "^4.2.1",
16 | "ts-node": "^10.9.1",
17 | "typescript": "^4.9.3"
18 | },
19 | "devDependencies": {
20 | "git-commit-msg-linter": "^4.2.1",
21 | "prettier": "2.8.7"
22 | }
23 | },
24 | "node_modules/@cspotcode/source-map-support": {
25 | "version": "0.8.1",
26 | "resolved": "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.8.1.tgz",
27 | "integrity": "sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw==",
28 | "dependencies": {
29 | "@jridgewell/trace-mapping": "0.3.9"
30 | },
31 | "engines": {
32 | "node": ">=12"
33 | }
34 | },
35 | "node_modules/@jridgewell/resolve-uri": {
36 | "version": "3.1.0",
37 | "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz",
38 | "integrity": "sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w==",
39 | "engines": {
40 | "node": ">=6.0.0"
41 | }
42 | },
43 | "node_modules/@jridgewell/sourcemap-codec": {
44 | "version": "1.4.14",
45 | "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz",
46 | "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw=="
47 | },
48 | "node_modules/@jridgewell/trace-mapping": {
49 | "version": "0.3.9",
50 | "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz",
51 | "integrity": "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==",
52 | "dependencies": {
53 | "@jridgewell/resolve-uri": "^3.0.3",
54 | "@jridgewell/sourcemap-codec": "^1.4.10"
55 | }
56 | },
57 | "node_modules/@nodelib/fs.scandir": {
58 | "version": "2.1.5",
59 | "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz",
60 | "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==",
61 | "dependencies": {
62 | "@nodelib/fs.stat": "2.0.5",
63 | "run-parallel": "^1.1.9"
64 | },
65 | "engines": {
66 | "node": ">= 8"
67 | }
68 | },
69 | "node_modules/@nodelib/fs.stat": {
70 | "version": "2.0.5",
71 | "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz",
72 | "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==",
73 | "engines": {
74 | "node": ">= 8"
75 | }
76 | },
77 | "node_modules/@nodelib/fs.walk": {
78 | "version": "1.2.8",
79 | "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz",
80 | "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==",
81 | "dependencies": {
82 | "@nodelib/fs.scandir": "2.1.5",
83 | "fastq": "^1.6.0"
84 | },
85 | "engines": {
86 | "node": ">= 8"
87 | }
88 | },
89 | "node_modules/@tsconfig/node10": {
90 | "version": "1.0.8",
91 | "resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.8.tgz",
92 | "integrity": "sha512-6XFfSQmMgq0CFLY1MslA/CPUfhIL919M1rMsa5lP2P097N2Wd1sSX0tx1u4olM16fLNhtHZpRhedZJphNJqmZg=="
93 | },
94 | "node_modules/@tsconfig/node12": {
95 | "version": "1.0.9",
96 | "resolved": "https://registry.npmjs.org/@tsconfig/node12/-/node12-1.0.9.tgz",
97 | "integrity": "sha512-/yBMcem+fbvhSREH+s14YJi18sp7J9jpuhYByADT2rypfajMZZN4WQ6zBGgBKp53NKmqI36wFYDb3yaMPurITw=="
98 | },
99 | "node_modules/@tsconfig/node14": {
100 | "version": "1.0.1",
101 | "resolved": "https://registry.npmjs.org/@tsconfig/node14/-/node14-1.0.1.tgz",
102 | "integrity": "sha512-509r2+yARFfHHE7T6Puu2jjkoycftovhXRqW328PDXTVGKihlb1P8Z9mMZH04ebyajfRY7dedfGynlrFHJUQCg=="
103 | },
104 | "node_modules/@tsconfig/node16": {
105 | "version": "1.0.3",
106 | "resolved": "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.3.tgz",
107 | "integrity": "sha512-yOlFc+7UtL/89t2ZhjPvvB/DeAr3r+Dq58IgzsFkOAvVC6NMJXmCGjbptdXdR9qsX7pKcTL+s87FtYREi2dEEQ=="
108 | },
109 | "node_modules/@types/json-schema": {
110 | "version": "7.0.11",
111 | "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.11.tgz",
112 | "integrity": "sha512-wOuvG1SN4Us4rez+tylwwwCV1psiNVOkJeM3AUWUNWg/jDQY2+HE/444y5gc+jBmRqASOm2Oeh5c1axHobwRKQ=="
113 | },
114 | "node_modules/@types/semver": {
115 | "version": "7.3.13",
116 | "resolved": "https://registry.npmjs.org/@types/semver/-/semver-7.3.13.tgz",
117 | "integrity": "sha512-21cFJr9z3g5dW8B0CVI9g2O9beqaThGQ6ZFBqHfwhzLDKUxaqTIy3vnfah/UPkfOiF2pLq+tGz+W8RyCskuslw=="
118 | },
119 | "node_modules/@typescript-eslint/eslint-plugin": {
120 | "version": "5.44.0",
121 | "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.44.0.tgz",
122 | "integrity": "sha512-j5ULd7FmmekcyWeArx+i8x7sdRHzAtXTkmDPthE4amxZOWKFK7bomoJ4r7PJ8K7PoMzD16U8MmuZFAonr1ERvw==",
123 | "dependencies": {
124 | "@typescript-eslint/scope-manager": "5.44.0",
125 | "@typescript-eslint/type-utils": "5.44.0",
126 | "@typescript-eslint/utils": "5.44.0",
127 | "debug": "^4.3.4",
128 | "ignore": "^5.2.0",
129 | "natural-compare-lite": "^1.4.0",
130 | "regexpp": "^3.2.0",
131 | "semver": "^7.3.7",
132 | "tsutils": "^3.21.0"
133 | },
134 | "engines": {
135 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
136 | },
137 | "funding": {
138 | "type": "opencollective",
139 | "url": "https://opencollective.com/typescript-eslint"
140 | },
141 | "peerDependencies": {
142 | "@typescript-eslint/parser": "^5.0.0",
143 | "eslint": "^6.0.0 || ^7.0.0 || ^8.0.0"
144 | },
145 | "peerDependenciesMeta": {
146 | "typescript": {
147 | "optional": true
148 | }
149 | }
150 | },
151 | "node_modules/@typescript-eslint/parser": {
152 | "version": "5.44.0",
153 | "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-5.44.0.tgz",
154 | "integrity": "sha512-H7LCqbZnKqkkgQHaKLGC6KUjt3pjJDx8ETDqmwncyb6PuoigYajyAwBGz08VU/l86dZWZgI4zm5k2VaKqayYyA==",
155 | "dependencies": {
156 | "@typescript-eslint/scope-manager": "5.44.0",
157 | "@typescript-eslint/types": "5.44.0",
158 | "@typescript-eslint/typescript-estree": "5.44.0",
159 | "debug": "^4.3.4"
160 | },
161 | "engines": {
162 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
163 | },
164 | "funding": {
165 | "type": "opencollective",
166 | "url": "https://opencollective.com/typescript-eslint"
167 | },
168 | "peerDependencies": {
169 | "eslint": "^6.0.0 || ^7.0.0 || ^8.0.0"
170 | },
171 | "peerDependenciesMeta": {
172 | "typescript": {
173 | "optional": true
174 | }
175 | }
176 | },
177 | "node_modules/@typescript-eslint/scope-manager": {
178 | "version": "5.44.0",
179 | "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-5.44.0.tgz",
180 | "integrity": "sha512-2pKml57KusI0LAhgLKae9kwWeITZ7IsZs77YxyNyIVOwQ1kToyXRaJLl+uDEXzMN5hnobKUOo2gKntK9H1YL8g==",
181 | "dependencies": {
182 | "@typescript-eslint/types": "5.44.0",
183 | "@typescript-eslint/visitor-keys": "5.44.0"
184 | },
185 | "engines": {
186 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
187 | },
188 | "funding": {
189 | "type": "opencollective",
190 | "url": "https://opencollective.com/typescript-eslint"
191 | }
192 | },
193 | "node_modules/@typescript-eslint/type-utils": {
194 | "version": "5.44.0",
195 | "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-5.44.0.tgz",
196 | "integrity": "sha512-A1u0Yo5wZxkXPQ7/noGkRhV4J9opcymcr31XQtOzcc5nO/IHN2E2TPMECKWYpM3e6olWEM63fq/BaL1wEYnt/w==",
197 | "dependencies": {
198 | "@typescript-eslint/typescript-estree": "5.44.0",
199 | "@typescript-eslint/utils": "5.44.0",
200 | "debug": "^4.3.4",
201 | "tsutils": "^3.21.0"
202 | },
203 | "engines": {
204 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
205 | },
206 | "funding": {
207 | "type": "opencollective",
208 | "url": "https://opencollective.com/typescript-eslint"
209 | },
210 | "peerDependencies": {
211 | "eslint": "*"
212 | },
213 | "peerDependenciesMeta": {
214 | "typescript": {
215 | "optional": true
216 | }
217 | }
218 | },
219 | "node_modules/@typescript-eslint/types": {
220 | "version": "5.44.0",
221 | "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-5.44.0.tgz",
222 | "integrity": "sha512-Tp+zDnHmGk4qKR1l+Y1rBvpjpm5tGXX339eAlRBDg+kgZkz9Bw+pqi4dyseOZMsGuSH69fYfPJCBKBrbPCxYFQ==",
223 | "engines": {
224 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
225 | },
226 | "funding": {
227 | "type": "opencollective",
228 | "url": "https://opencollective.com/typescript-eslint"
229 | }
230 | },
231 | "node_modules/@typescript-eslint/typescript-estree": {
232 | "version": "5.44.0",
233 | "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-5.44.0.tgz",
234 | "integrity": "sha512-M6Jr+RM7M5zeRj2maSfsZK2660HKAJawv4Ud0xT+yauyvgrsHu276VtXlKDFnEmhG+nVEd0fYZNXGoAgxwDWJw==",
235 | "dependencies": {
236 | "@typescript-eslint/types": "5.44.0",
237 | "@typescript-eslint/visitor-keys": "5.44.0",
238 | "debug": "^4.3.4",
239 | "globby": "^11.1.0",
240 | "is-glob": "^4.0.3",
241 | "semver": "^7.3.7",
242 | "tsutils": "^3.21.0"
243 | },
244 | "engines": {
245 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
246 | },
247 | "funding": {
248 | "type": "opencollective",
249 | "url": "https://opencollective.com/typescript-eslint"
250 | },
251 | "peerDependenciesMeta": {
252 | "typescript": {
253 | "optional": true
254 | }
255 | }
256 | },
257 | "node_modules/@typescript-eslint/utils": {
258 | "version": "5.44.0",
259 | "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-5.44.0.tgz",
260 | "integrity": "sha512-fMzA8LLQ189gaBjS0MZszw5HBdZgVwxVFShCO3QN+ws3GlPkcy9YuS3U4wkT6su0w+Byjq3mS3uamy9HE4Yfjw==",
261 | "dependencies": {
262 | "@types/json-schema": "^7.0.9",
263 | "@types/semver": "^7.3.12",
264 | "@typescript-eslint/scope-manager": "5.44.0",
265 | "@typescript-eslint/types": "5.44.0",
266 | "@typescript-eslint/typescript-estree": "5.44.0",
267 | "eslint-scope": "^5.1.1",
268 | "eslint-utils": "^3.0.0",
269 | "semver": "^7.3.7"
270 | },
271 | "engines": {
272 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
273 | },
274 | "funding": {
275 | "type": "opencollective",
276 | "url": "https://opencollective.com/typescript-eslint"
277 | },
278 | "peerDependencies": {
279 | "eslint": "^6.0.0 || ^7.0.0 || ^8.0.0"
280 | }
281 | },
282 | "node_modules/@typescript-eslint/visitor-keys": {
283 | "version": "5.44.0",
284 | "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-5.44.0.tgz",
285 | "integrity": "sha512-a48tLG8/4m62gPFbJ27FxwCOqPKxsb8KC3HkmYoq2As/4YyjQl1jDbRr1s63+g4FS/iIehjmN3L5UjmKva1HzQ==",
286 | "dependencies": {
287 | "@typescript-eslint/types": "5.44.0",
288 | "eslint-visitor-keys": "^3.3.0"
289 | },
290 | "engines": {
291 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
292 | },
293 | "funding": {
294 | "type": "opencollective",
295 | "url": "https://opencollective.com/typescript-eslint"
296 | }
297 | },
298 | "node_modules/acorn-walk": {
299 | "version": "8.2.0",
300 | "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz",
301 | "integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==",
302 | "engines": {
303 | "node": ">=0.4.0"
304 | }
305 | },
306 | "node_modules/ansi-styles": {
307 | "version": "3.2.1",
308 | "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz",
309 | "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==",
310 | "dev": true,
311 | "dependencies": {
312 | "color-convert": "^1.9.0"
313 | },
314 | "engines": {
315 | "node": ">=4"
316 | }
317 | },
318 | "node_modules/arg": {
319 | "version": "4.1.3",
320 | "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz",
321 | "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA=="
322 | },
323 | "node_modules/array-union": {
324 | "version": "2.1.0",
325 | "resolved": "https://registry.npmjs.org/array-union/-/array-union-2.1.0.tgz",
326 | "integrity": "sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==",
327 | "engines": {
328 | "node": ">=8"
329 | }
330 | },
331 | "node_modules/braces": {
332 | "version": "3.0.2",
333 | "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz",
334 | "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==",
335 | "dependencies": {
336 | "fill-range": "^7.0.1"
337 | },
338 | "engines": {
339 | "node": ">=8"
340 | }
341 | },
342 | "node_modules/chalk": {
343 | "version": "2.4.2",
344 | "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz",
345 | "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==",
346 | "dev": true,
347 | "dependencies": {
348 | "ansi-styles": "^3.2.1",
349 | "escape-string-regexp": "^1.0.5",
350 | "supports-color": "^5.3.0"
351 | },
352 | "engines": {
353 | "node": ">=4"
354 | }
355 | },
356 | "node_modules/chalk/node_modules/has-flag": {
357 | "version": "3.0.0",
358 | "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz",
359 | "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==",
360 | "dev": true,
361 | "engines": {
362 | "node": ">=4"
363 | }
364 | },
365 | "node_modules/chalk/node_modules/supports-color": {
366 | "version": "5.5.0",
367 | "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz",
368 | "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==",
369 | "dev": true,
370 | "dependencies": {
371 | "has-flag": "^3.0.0"
372 | },
373 | "engines": {
374 | "node": ">=4"
375 | }
376 | },
377 | "node_modules/color-convert": {
378 | "version": "1.9.3",
379 | "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz",
380 | "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==",
381 | "dev": true,
382 | "dependencies": {
383 | "color-name": "1.1.3"
384 | }
385 | },
386 | "node_modules/color-name": {
387 | "version": "1.1.3",
388 | "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz",
389 | "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==",
390 | "dev": true
391 | },
392 | "node_modules/create-require": {
393 | "version": "1.1.1",
394 | "resolved": "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz",
395 | "integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ=="
396 | },
397 | "node_modules/debug": {
398 | "version": "4.3.4",
399 | "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz",
400 | "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==",
401 | "dependencies": {
402 | "ms": "2.1.2"
403 | },
404 | "engines": {
405 | "node": ">=6.0"
406 | },
407 | "peerDependenciesMeta": {
408 | "supports-color": {
409 | "optional": true
410 | }
411 | }
412 | },
413 | "node_modules/did-you-mean": {
414 | "version": "0.0.1",
415 | "resolved": "https://registry.npmjs.org/did-you-mean/-/did-you-mean-0.0.1.tgz",
416 | "integrity": "sha512-rKxPpbrHr4/u8VMPde6Z3DhbGoXw7kepHZIU2FGs+IU+LKnhEIlw1cx80FZ7fLruJXDyu0slKMai2FhPRZjwxQ==",
417 | "dev": true,
418 | "dependencies": {
419 | "levenshtein": "*",
420 | "underscore": "*"
421 | }
422 | },
423 | "node_modules/diff": {
424 | "version": "4.0.2",
425 | "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz",
426 | "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==",
427 | "engines": {
428 | "node": ">=0.3.1"
429 | }
430 | },
431 | "node_modules/dir-glob": {
432 | "version": "3.0.1",
433 | "resolved": "https://registry.npmjs.org/dir-glob/-/dir-glob-3.0.1.tgz",
434 | "integrity": "sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==",
435 | "dependencies": {
436 | "path-type": "^4.0.0"
437 | },
438 | "engines": {
439 | "node": ">=8"
440 | }
441 | },
442 | "node_modules/escape-string-regexp": {
443 | "version": "1.0.5",
444 | "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz",
445 | "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==",
446 | "dev": true,
447 | "engines": {
448 | "node": ">=0.8.0"
449 | }
450 | },
451 | "node_modules/eslint-config-prettier": {
452 | "version": "8.5.0",
453 | "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-8.5.0.tgz",
454 | "integrity": "sha512-obmWKLUNCnhtQRKc+tmnYuQl0pFU1ibYJQ5BGhTVB08bHe9wC8qUeG7c08dj9XX+AuPj1YSGSQIHl1pnDHZR0Q==",
455 | "bin": {
456 | "eslint-config-prettier": "bin/cli.js"
457 | },
458 | "peerDependencies": {
459 | "eslint": ">=7.0.0"
460 | }
461 | },
462 | "node_modules/eslint-plugin-prettier": {
463 | "version": "4.2.1",
464 | "resolved": "https://registry.npmjs.org/eslint-plugin-prettier/-/eslint-plugin-prettier-4.2.1.tgz",
465 | "integrity": "sha512-f/0rXLXUt0oFYs8ra4w49wYZBG5GKZpAYsJSm6rnYL5uVDjd+zowwMwVZHnAjf4edNrKpCDYfXDgmRE/Ak7QyQ==",
466 | "dependencies": {
467 | "prettier-linter-helpers": "^1.0.0"
468 | },
469 | "engines": {
470 | "node": ">=12.0.0"
471 | },
472 | "peerDependencies": {
473 | "eslint": ">=7.28.0",
474 | "prettier": ">=2.0.0"
475 | },
476 | "peerDependenciesMeta": {
477 | "eslint-config-prettier": {
478 | "optional": true
479 | }
480 | }
481 | },
482 | "node_modules/eslint-scope": {
483 | "version": "5.1.1",
484 | "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.1.1.tgz",
485 | "integrity": "sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw==",
486 | "dependencies": {
487 | "esrecurse": "^4.3.0",
488 | "estraverse": "^4.1.1"
489 | },
490 | "engines": {
491 | "node": ">=8.0.0"
492 | }
493 | },
494 | "node_modules/eslint-utils": {
495 | "version": "3.0.0",
496 | "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-3.0.0.tgz",
497 | "integrity": "sha512-uuQC43IGctw68pJA1RgbQS8/NP7rch6Cwd4j3ZBtgo4/8Flj4eGE7ZYSZRN3iq5pVUv6GPdW5Z1RFleo84uLDA==",
498 | "dependencies": {
499 | "eslint-visitor-keys": "^2.0.0"
500 | },
501 | "engines": {
502 | "node": "^10.0.0 || ^12.0.0 || >= 14.0.0"
503 | },
504 | "funding": {
505 | "url": "https://github.com/sponsors/mysticatea"
506 | },
507 | "peerDependencies": {
508 | "eslint": ">=5"
509 | }
510 | },
511 | "node_modules/eslint-utils/node_modules/eslint-visitor-keys": {
512 | "version": "2.1.0",
513 | "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-2.1.0.tgz",
514 | "integrity": "sha512-0rSmRBzXgDzIsD6mGdJgevzgezI534Cer5L/vyMX0kHzT/jiB43jRhd9YUlMGYLQy2zprNmoT8qasCGtY+QaKw==",
515 | "engines": {
516 | "node": ">=10"
517 | }
518 | },
519 | "node_modules/eslint-visitor-keys": {
520 | "version": "3.3.0",
521 | "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.3.0.tgz",
522 | "integrity": "sha512-mQ+suqKJVyeuwGYHAdjMFqjCyfl8+Ldnxuyp3ldiMBFKkvytrXUZWaiPCEav8qDHKty44bD+qV1IP4T+w+xXRA==",
523 | "engines": {
524 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
525 | }
526 | },
527 | "node_modules/esrecurse": {
528 | "version": "4.3.0",
529 | "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz",
530 | "integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==",
531 | "dependencies": {
532 | "estraverse": "^5.2.0"
533 | },
534 | "engines": {
535 | "node": ">=4.0"
536 | }
537 | },
538 | "node_modules/esrecurse/node_modules/estraverse": {
539 | "version": "5.3.0",
540 | "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz",
541 | "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==",
542 | "engines": {
543 | "node": ">=4.0"
544 | }
545 | },
546 | "node_modules/estraverse": {
547 | "version": "4.3.0",
548 | "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.3.0.tgz",
549 | "integrity": "sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==",
550 | "engines": {
551 | "node": ">=4.0"
552 | }
553 | },
554 | "node_modules/fast-diff": {
555 | "version": "1.2.0",
556 | "resolved": "https://registry.npmjs.org/fast-diff/-/fast-diff-1.2.0.tgz",
557 | "integrity": "sha512-xJuoT5+L99XlZ8twedaRf6Ax2TgQVxvgZOYoPKqZufmJib0tL2tegPBOZb1pVNgIhlqDlA0eO0c3wBvQcmzx4w=="
558 | },
559 | "node_modules/fast-glob": {
560 | "version": "3.2.12",
561 | "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.2.12.tgz",
562 | "integrity": "sha512-DVj4CQIYYow0BlaelwK1pHl5n5cRSJfM60UA0zK891sVInoPri2Ekj7+e1CT3/3qxXenpI+nBBmQAcJPJgaj4w==",
563 | "dependencies": {
564 | "@nodelib/fs.stat": "^2.0.2",
565 | "@nodelib/fs.walk": "^1.2.3",
566 | "glob-parent": "^5.1.2",
567 | "merge2": "^1.3.0",
568 | "micromatch": "^4.0.4"
569 | },
570 | "engines": {
571 | "node": ">=8.6.0"
572 | }
573 | },
574 | "node_modules/fastq": {
575 | "version": "1.13.0",
576 | "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.13.0.tgz",
577 | "integrity": "sha512-YpkpUnK8od0o1hmeSc7UUs/eB/vIPWJYjKck2QKIzAf71Vm1AAQ3EbuZB3g2JIy+pg+ERD0vqI79KyZiB2e2Nw==",
578 | "dependencies": {
579 | "reusify": "^1.0.4"
580 | }
581 | },
582 | "node_modules/fill-range": {
583 | "version": "7.0.1",
584 | "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz",
585 | "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==",
586 | "dependencies": {
587 | "to-regex-range": "^5.0.1"
588 | },
589 | "engines": {
590 | "node": ">=8"
591 | }
592 | },
593 | "node_modules/git-commit-msg-linter": {
594 | "version": "4.2.1",
595 | "resolved": "https://registry.npmjs.org/git-commit-msg-linter/-/git-commit-msg-linter-4.2.1.tgz",
596 | "integrity": "sha512-4iw0N0Sdga5wWN527/Oei6wkQGuWBhUEioonaM3HcaddEP8rYQPApGvfNvCkA+spd0wo59ToK+9DgHaHu1mAqg==",
597 | "dev": true,
598 | "hasInstallScript": true,
599 | "dependencies": {
600 | "chalk": "^2.4.2",
601 | "did-you-mean": "^0.0.1",
602 | "supports-color": "^8.1.1"
603 | },
604 | "engines": {
605 | "node": ">= 8.0.0"
606 | }
607 | },
608 | "node_modules/glob-parent": {
609 | "version": "5.1.2",
610 | "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz",
611 | "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==",
612 | "dependencies": {
613 | "is-glob": "^4.0.1"
614 | },
615 | "engines": {
616 | "node": ">= 6"
617 | }
618 | },
619 | "node_modules/globby": {
620 | "version": "11.1.0",
621 | "resolved": "https://registry.npmjs.org/globby/-/globby-11.1.0.tgz",
622 | "integrity": "sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==",
623 | "dependencies": {
624 | "array-union": "^2.1.0",
625 | "dir-glob": "^3.0.1",
626 | "fast-glob": "^3.2.9",
627 | "ignore": "^5.2.0",
628 | "merge2": "^1.4.1",
629 | "slash": "^3.0.0"
630 | },
631 | "engines": {
632 | "node": ">=10"
633 | },
634 | "funding": {
635 | "url": "https://github.com/sponsors/sindresorhus"
636 | }
637 | },
638 | "node_modules/has-flag": {
639 | "version": "4.0.0",
640 | "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
641 | "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==",
642 | "dev": true,
643 | "engines": {
644 | "node": ">=8"
645 | }
646 | },
647 | "node_modules/ignore": {
648 | "version": "5.2.0",
649 | "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.2.0.tgz",
650 | "integrity": "sha512-CmxgYGiEPCLhfLnpPp1MoRmifwEIOgjcHXxOBjv7mY96c+eWScsOP9c112ZyLdWHi0FxHjI+4uVhKYp/gcdRmQ==",
651 | "engines": {
652 | "node": ">= 4"
653 | }
654 | },
655 | "node_modules/is-extglob": {
656 | "version": "2.1.1",
657 | "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz",
658 | "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==",
659 | "engines": {
660 | "node": ">=0.10.0"
661 | }
662 | },
663 | "node_modules/is-glob": {
664 | "version": "4.0.3",
665 | "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz",
666 | "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==",
667 | "dependencies": {
668 | "is-extglob": "^2.1.1"
669 | },
670 | "engines": {
671 | "node": ">=0.10.0"
672 | }
673 | },
674 | "node_modules/is-number": {
675 | "version": "7.0.0",
676 | "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz",
677 | "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==",
678 | "engines": {
679 | "node": ">=0.12.0"
680 | }
681 | },
682 | "node_modules/levenshtein": {
683 | "version": "1.0.5",
684 | "resolved": "https://registry.npmjs.org/levenshtein/-/levenshtein-1.0.5.tgz",
685 | "integrity": "sha512-UQf1nnmxjl7O0+snDXj2YF2r74Gkya8ZpnegrUBYN9tikh2dtxV/ey8e07BO5wwo0i76yjOvbDhFHdcPEiH9aA==",
686 | "dev": true,
687 | "engines": [
688 | "node >=0.2.0"
689 | ]
690 | },
691 | "node_modules/lru-cache": {
692 | "version": "6.0.0",
693 | "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz",
694 | "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==",
695 | "dependencies": {
696 | "yallist": "^4.0.0"
697 | },
698 | "engines": {
699 | "node": ">=10"
700 | }
701 | },
702 | "node_modules/make-error": {
703 | "version": "1.3.6",
704 | "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz",
705 | "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw=="
706 | },
707 | "node_modules/merge2": {
708 | "version": "1.4.1",
709 | "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz",
710 | "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==",
711 | "engines": {
712 | "node": ">= 8"
713 | }
714 | },
715 | "node_modules/micromatch": {
716 | "version": "4.0.5",
717 | "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.5.tgz",
718 | "integrity": "sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA==",
719 | "dependencies": {
720 | "braces": "^3.0.2",
721 | "picomatch": "^2.3.1"
722 | },
723 | "engines": {
724 | "node": ">=8.6"
725 | }
726 | },
727 | "node_modules/ms": {
728 | "version": "2.1.2",
729 | "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz",
730 | "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w=="
731 | },
732 | "node_modules/natural-compare-lite": {
733 | "version": "1.4.0",
734 | "resolved": "https://registry.npmjs.org/natural-compare-lite/-/natural-compare-lite-1.4.0.tgz",
735 | "integrity": "sha512-Tj+HTDSJJKaZnfiuw+iaF9skdPpTo2GtEly5JHnWV/hfv2Qj/9RKsGISQtLh2ox3l5EAGw487hnBee0sIJ6v2g=="
736 | },
737 | "node_modules/path-type": {
738 | "version": "4.0.0",
739 | "resolved": "https://registry.npmjs.org/path-type/-/path-type-4.0.0.tgz",
740 | "integrity": "sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==",
741 | "engines": {
742 | "node": ">=8"
743 | }
744 | },
745 | "node_modules/picomatch": {
746 | "version": "2.3.1",
747 | "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz",
748 | "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==",
749 | "engines": {
750 | "node": ">=8.6"
751 | },
752 | "funding": {
753 | "url": "https://github.com/sponsors/jonschlinkert"
754 | }
755 | },
756 | "node_modules/prettier": {
757 | "version": "2.8.7",
758 | "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.8.7.tgz",
759 | "integrity": "sha512-yPngTo3aXUUmyuTjeTUT75txrf+aMh9FiD7q9ZE/i6r0bPb22g4FsE6Y338PQX1bmfy08i9QQCB7/rcUAVntfw==",
760 | "dev": true,
761 | "bin": {
762 | "prettier": "bin-prettier.js"
763 | },
764 | "engines": {
765 | "node": ">=10.13.0"
766 | },
767 | "funding": {
768 | "url": "https://github.com/prettier/prettier?sponsor=1"
769 | }
770 | },
771 | "node_modules/prettier-linter-helpers": {
772 | "version": "1.0.0",
773 | "resolved": "https://registry.npmjs.org/prettier-linter-helpers/-/prettier-linter-helpers-1.0.0.tgz",
774 | "integrity": "sha512-GbK2cP9nraSSUF9N2XwUwqfzlAFlMNYYl+ShE/V+H8a9uNl/oUqB1w2EL54Jh0OlyRSd8RfWYJ3coVS4TROP2w==",
775 | "dependencies": {
776 | "fast-diff": "^1.1.2"
777 | },
778 | "engines": {
779 | "node": ">=6.0.0"
780 | }
781 | },
782 | "node_modules/queue-microtask": {
783 | "version": "1.2.3",
784 | "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz",
785 | "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==",
786 | "funding": [
787 | {
788 | "type": "github",
789 | "url": "https://github.com/sponsors/feross"
790 | },
791 | {
792 | "type": "patreon",
793 | "url": "https://www.patreon.com/feross"
794 | },
795 | {
796 | "type": "consulting",
797 | "url": "https://feross.org/support"
798 | }
799 | ]
800 | },
801 | "node_modules/regexpp": {
802 | "version": "3.2.0",
803 | "resolved": "https://registry.npmjs.org/regexpp/-/regexpp-3.2.0.tgz",
804 | "integrity": "sha512-pq2bWo9mVD43nbts2wGv17XLiNLya+GklZ8kaDLV2Z08gDCsGpnKn9BFMepvWuHCbyVvY7J5o5+BVvoQbmlJLg==",
805 | "engines": {
806 | "node": ">=8"
807 | },
808 | "funding": {
809 | "url": "https://github.com/sponsors/mysticatea"
810 | }
811 | },
812 | "node_modules/reusify": {
813 | "version": "1.0.4",
814 | "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz",
815 | "integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==",
816 | "engines": {
817 | "iojs": ">=1.0.0",
818 | "node": ">=0.10.0"
819 | }
820 | },
821 | "node_modules/run-parallel": {
822 | "version": "1.2.0",
823 | "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz",
824 | "integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==",
825 | "funding": [
826 | {
827 | "type": "github",
828 | "url": "https://github.com/sponsors/feross"
829 | },
830 | {
831 | "type": "patreon",
832 | "url": "https://www.patreon.com/feross"
833 | },
834 | {
835 | "type": "consulting",
836 | "url": "https://feross.org/support"
837 | }
838 | ],
839 | "dependencies": {
840 | "queue-microtask": "^1.2.2"
841 | }
842 | },
843 | "node_modules/semver": {
844 | "version": "7.3.8",
845 | "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.8.tgz",
846 | "integrity": "sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A==",
847 | "dependencies": {
848 | "lru-cache": "^6.0.0"
849 | },
850 | "bin": {
851 | "semver": "bin/semver.js"
852 | },
853 | "engines": {
854 | "node": ">=10"
855 | }
856 | },
857 | "node_modules/slash": {
858 | "version": "3.0.0",
859 | "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz",
860 | "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==",
861 | "engines": {
862 | "node": ">=8"
863 | }
864 | },
865 | "node_modules/supports-color": {
866 | "version": "8.1.1",
867 | "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz",
868 | "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==",
869 | "dev": true,
870 | "dependencies": {
871 | "has-flag": "^4.0.0"
872 | },
873 | "engines": {
874 | "node": ">=10"
875 | },
876 | "funding": {
877 | "url": "https://github.com/chalk/supports-color?sponsor=1"
878 | }
879 | },
880 | "node_modules/to-regex-range": {
881 | "version": "5.0.1",
882 | "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz",
883 | "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==",
884 | "dependencies": {
885 | "is-number": "^7.0.0"
886 | },
887 | "engines": {
888 | "node": ">=8.0"
889 | }
890 | },
891 | "node_modules/ts-node": {
892 | "version": "10.9.1",
893 | "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.9.1.tgz",
894 | "integrity": "sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw==",
895 | "dependencies": {
896 | "@cspotcode/source-map-support": "^0.8.0",
897 | "@tsconfig/node10": "^1.0.7",
898 | "@tsconfig/node12": "^1.0.7",
899 | "@tsconfig/node14": "^1.0.0",
900 | "@tsconfig/node16": "^1.0.2",
901 | "acorn": "^8.4.1",
902 | "acorn-walk": "^8.1.1",
903 | "arg": "^4.1.0",
904 | "create-require": "^1.1.0",
905 | "diff": "^4.0.1",
906 | "make-error": "^1.1.1",
907 | "v8-compile-cache-lib": "^3.0.1",
908 | "yn": "3.1.1"
909 | },
910 | "bin": {
911 | "ts-node": "dist/bin.js",
912 | "ts-node-cwd": "dist/bin-cwd.js",
913 | "ts-node-esm": "dist/bin-esm.js",
914 | "ts-node-script": "dist/bin-script.js",
915 | "ts-node-transpile-only": "dist/bin-transpile.js",
916 | "ts-script": "dist/bin-script-deprecated.js"
917 | },
918 | "peerDependencies": {
919 | "@swc/core": ">=1.2.50",
920 | "@swc/wasm": ">=1.2.50",
921 | "@types/node": "*",
922 | "typescript": ">=2.7"
923 | },
924 | "peerDependenciesMeta": {
925 | "@swc/core": {
926 | "optional": true
927 | },
928 | "@swc/wasm": {
929 | "optional": true
930 | }
931 | }
932 | },
933 | "node_modules/ts-node/node_modules/acorn": {
934 | "version": "8.8.1",
935 | "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.8.1.tgz",
936 | "integrity": "sha512-7zFpHzhnqYKrkYdUjF1HI1bzd0VygEGX8lFk4k5zVMqHEoES+P+7TKI+EvLO9WVMJ8eekdO0aDEK044xTXwPPA==",
937 | "bin": {
938 | "acorn": "bin/acorn"
939 | },
940 | "engines": {
941 | "node": ">=0.4.0"
942 | }
943 | },
944 | "node_modules/tslib": {
945 | "version": "1.14.1",
946 | "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz",
947 | "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg=="
948 | },
949 | "node_modules/tsutils": {
950 | "version": "3.21.0",
951 | "resolved": "https://registry.npmjs.org/tsutils/-/tsutils-3.21.0.tgz",
952 | "integrity": "sha512-mHKK3iUXL+3UF6xL5k0PEhKRUBKPBCv/+RkEOpjRWxxx27KKRBmmA60A9pgOUvMi8GKhRMPEmjBRPzs2W7O1OA==",
953 | "dependencies": {
954 | "tslib": "^1.8.1"
955 | },
956 | "engines": {
957 | "node": ">= 6"
958 | },
959 | "peerDependencies": {
960 | "typescript": ">=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta"
961 | }
962 | },
963 | "node_modules/typescript": {
964 | "version": "4.9.3",
965 | "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.9.3.tgz",
966 | "integrity": "sha512-CIfGzTelbKNEnLpLdGFgdyKhG23CKdKgQPOBc+OUNrkJ2vr+KSzsSV5kq5iWhEQbok+quxgGzrAtGWCyU7tHnA==",
967 | "bin": {
968 | "tsc": "bin/tsc",
969 | "tsserver": "bin/tsserver"
970 | },
971 | "engines": {
972 | "node": ">=4.2.0"
973 | }
974 | },
975 | "node_modules/underscore": {
976 | "version": "1.13.6",
977 | "resolved": "https://registry.npmjs.org/underscore/-/underscore-1.13.6.tgz",
978 | "integrity": "sha512-+A5Sja4HP1M08MaXya7p5LvjuM7K6q/2EaC0+iovj/wOcMsTzMvDFbasi/oSapiwOlt252IqsKqPjCl7huKS0A==",
979 | "dev": true
980 | },
981 | "node_modules/v8-compile-cache-lib": {
982 | "version": "3.0.1",
983 | "resolved": "https://registry.npmjs.org/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz",
984 | "integrity": "sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg=="
985 | },
986 | "node_modules/yallist": {
987 | "version": "4.0.0",
988 | "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz",
989 | "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A=="
990 | },
991 | "node_modules/yn": {
992 | "version": "3.1.1",
993 | "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz",
994 | "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==",
995 | "engines": {
996 | "node": ">=6"
997 | }
998 | }
999 | },
1000 | "dependencies": {
1001 | "@cspotcode/source-map-support": {
1002 | "version": "0.8.1",
1003 | "resolved": "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.8.1.tgz",
1004 | "integrity": "sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw==",
1005 | "requires": {
1006 | "@jridgewell/trace-mapping": "0.3.9"
1007 | }
1008 | },
1009 | "@jridgewell/resolve-uri": {
1010 | "version": "3.1.0",
1011 | "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz",
1012 | "integrity": "sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w=="
1013 | },
1014 | "@jridgewell/sourcemap-codec": {
1015 | "version": "1.4.14",
1016 | "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz",
1017 | "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw=="
1018 | },
1019 | "@jridgewell/trace-mapping": {
1020 | "version": "0.3.9",
1021 | "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz",
1022 | "integrity": "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==",
1023 | "requires": {
1024 | "@jridgewell/resolve-uri": "^3.0.3",
1025 | "@jridgewell/sourcemap-codec": "^1.4.10"
1026 | }
1027 | },
1028 | "@nodelib/fs.scandir": {
1029 | "version": "2.1.5",
1030 | "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz",
1031 | "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==",
1032 | "requires": {
1033 | "@nodelib/fs.stat": "2.0.5",
1034 | "run-parallel": "^1.1.9"
1035 | }
1036 | },
1037 | "@nodelib/fs.stat": {
1038 | "version": "2.0.5",
1039 | "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz",
1040 | "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A=="
1041 | },
1042 | "@nodelib/fs.walk": {
1043 | "version": "1.2.8",
1044 | "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz",
1045 | "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==",
1046 | "requires": {
1047 | "@nodelib/fs.scandir": "2.1.5",
1048 | "fastq": "^1.6.0"
1049 | }
1050 | },
1051 | "@tsconfig/node10": {
1052 | "version": "1.0.8",
1053 | "resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.8.tgz",
1054 | "integrity": "sha512-6XFfSQmMgq0CFLY1MslA/CPUfhIL919M1rMsa5lP2P097N2Wd1sSX0tx1u4olM16fLNhtHZpRhedZJphNJqmZg=="
1055 | },
1056 | "@tsconfig/node12": {
1057 | "version": "1.0.9",
1058 | "resolved": "https://registry.npmjs.org/@tsconfig/node12/-/node12-1.0.9.tgz",
1059 | "integrity": "sha512-/yBMcem+fbvhSREH+s14YJi18sp7J9jpuhYByADT2rypfajMZZN4WQ6zBGgBKp53NKmqI36wFYDb3yaMPurITw=="
1060 | },
1061 | "@tsconfig/node14": {
1062 | "version": "1.0.1",
1063 | "resolved": "https://registry.npmjs.org/@tsconfig/node14/-/node14-1.0.1.tgz",
1064 | "integrity": "sha512-509r2+yARFfHHE7T6Puu2jjkoycftovhXRqW328PDXTVGKihlb1P8Z9mMZH04ebyajfRY7dedfGynlrFHJUQCg=="
1065 | },
1066 | "@tsconfig/node16": {
1067 | "version": "1.0.3",
1068 | "resolved": "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.3.tgz",
1069 | "integrity": "sha512-yOlFc+7UtL/89t2ZhjPvvB/DeAr3r+Dq58IgzsFkOAvVC6NMJXmCGjbptdXdR9qsX7pKcTL+s87FtYREi2dEEQ=="
1070 | },
1071 | "@types/json-schema": {
1072 | "version": "7.0.11",
1073 | "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.11.tgz",
1074 | "integrity": "sha512-wOuvG1SN4Us4rez+tylwwwCV1psiNVOkJeM3AUWUNWg/jDQY2+HE/444y5gc+jBmRqASOm2Oeh5c1axHobwRKQ=="
1075 | },
1076 | "@types/semver": {
1077 | "version": "7.3.13",
1078 | "resolved": "https://registry.npmjs.org/@types/semver/-/semver-7.3.13.tgz",
1079 | "integrity": "sha512-21cFJr9z3g5dW8B0CVI9g2O9beqaThGQ6ZFBqHfwhzLDKUxaqTIy3vnfah/UPkfOiF2pLq+tGz+W8RyCskuslw=="
1080 | },
1081 | "@typescript-eslint/eslint-plugin": {
1082 | "version": "5.44.0",
1083 | "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.44.0.tgz",
1084 | "integrity": "sha512-j5ULd7FmmekcyWeArx+i8x7sdRHzAtXTkmDPthE4amxZOWKFK7bomoJ4r7PJ8K7PoMzD16U8MmuZFAonr1ERvw==",
1085 | "requires": {
1086 | "@typescript-eslint/scope-manager": "5.44.0",
1087 | "@typescript-eslint/type-utils": "5.44.0",
1088 | "@typescript-eslint/utils": "5.44.0",
1089 | "debug": "^4.3.4",
1090 | "ignore": "^5.2.0",
1091 | "natural-compare-lite": "^1.4.0",
1092 | "regexpp": "^3.2.0",
1093 | "semver": "^7.3.7",
1094 | "tsutils": "^3.21.0"
1095 | }
1096 | },
1097 | "@typescript-eslint/parser": {
1098 | "version": "5.44.0",
1099 | "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-5.44.0.tgz",
1100 | "integrity": "sha512-H7LCqbZnKqkkgQHaKLGC6KUjt3pjJDx8ETDqmwncyb6PuoigYajyAwBGz08VU/l86dZWZgI4zm5k2VaKqayYyA==",
1101 | "requires": {
1102 | "@typescript-eslint/scope-manager": "5.44.0",
1103 | "@typescript-eslint/types": "5.44.0",
1104 | "@typescript-eslint/typescript-estree": "5.44.0",
1105 | "debug": "^4.3.4"
1106 | }
1107 | },
1108 | "@typescript-eslint/scope-manager": {
1109 | "version": "5.44.0",
1110 | "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-5.44.0.tgz",
1111 | "integrity": "sha512-2pKml57KusI0LAhgLKae9kwWeITZ7IsZs77YxyNyIVOwQ1kToyXRaJLl+uDEXzMN5hnobKUOo2gKntK9H1YL8g==",
1112 | "requires": {
1113 | "@typescript-eslint/types": "5.44.0",
1114 | "@typescript-eslint/visitor-keys": "5.44.0"
1115 | }
1116 | },
1117 | "@typescript-eslint/type-utils": {
1118 | "version": "5.44.0",
1119 | "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-5.44.0.tgz",
1120 | "integrity": "sha512-A1u0Yo5wZxkXPQ7/noGkRhV4J9opcymcr31XQtOzcc5nO/IHN2E2TPMECKWYpM3e6olWEM63fq/BaL1wEYnt/w==",
1121 | "requires": {
1122 | "@typescript-eslint/typescript-estree": "5.44.0",
1123 | "@typescript-eslint/utils": "5.44.0",
1124 | "debug": "^4.3.4",
1125 | "tsutils": "^3.21.0"
1126 | }
1127 | },
1128 | "@typescript-eslint/types": {
1129 | "version": "5.44.0",
1130 | "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-5.44.0.tgz",
1131 | "integrity": "sha512-Tp+zDnHmGk4qKR1l+Y1rBvpjpm5tGXX339eAlRBDg+kgZkz9Bw+pqi4dyseOZMsGuSH69fYfPJCBKBrbPCxYFQ=="
1132 | },
1133 | "@typescript-eslint/typescript-estree": {
1134 | "version": "5.44.0",
1135 | "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-5.44.0.tgz",
1136 | "integrity": "sha512-M6Jr+RM7M5zeRj2maSfsZK2660HKAJawv4Ud0xT+yauyvgrsHu276VtXlKDFnEmhG+nVEd0fYZNXGoAgxwDWJw==",
1137 | "requires": {
1138 | "@typescript-eslint/types": "5.44.0",
1139 | "@typescript-eslint/visitor-keys": "5.44.0",
1140 | "debug": "^4.3.4",
1141 | "globby": "^11.1.0",
1142 | "is-glob": "^4.0.3",
1143 | "semver": "^7.3.7",
1144 | "tsutils": "^3.21.0"
1145 | }
1146 | },
1147 | "@typescript-eslint/utils": {
1148 | "version": "5.44.0",
1149 | "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-5.44.0.tgz",
1150 | "integrity": "sha512-fMzA8LLQ189gaBjS0MZszw5HBdZgVwxVFShCO3QN+ws3GlPkcy9YuS3U4wkT6su0w+Byjq3mS3uamy9HE4Yfjw==",
1151 | "requires": {
1152 | "@types/json-schema": "^7.0.9",
1153 | "@types/semver": "^7.3.12",
1154 | "@typescript-eslint/scope-manager": "5.44.0",
1155 | "@typescript-eslint/types": "5.44.0",
1156 | "@typescript-eslint/typescript-estree": "5.44.0",
1157 | "eslint-scope": "^5.1.1",
1158 | "eslint-utils": "^3.0.0",
1159 | "semver": "^7.3.7"
1160 | }
1161 | },
1162 | "@typescript-eslint/visitor-keys": {
1163 | "version": "5.44.0",
1164 | "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-5.44.0.tgz",
1165 | "integrity": "sha512-a48tLG8/4m62gPFbJ27FxwCOqPKxsb8KC3HkmYoq2As/4YyjQl1jDbRr1s63+g4FS/iIehjmN3L5UjmKva1HzQ==",
1166 | "requires": {
1167 | "@typescript-eslint/types": "5.44.0",
1168 | "eslint-visitor-keys": "^3.3.0"
1169 | }
1170 | },
1171 | "acorn-walk": {
1172 | "version": "8.2.0",
1173 | "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz",
1174 | "integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA=="
1175 | },
1176 | "ansi-styles": {
1177 | "version": "3.2.1",
1178 | "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz",
1179 | "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==",
1180 | "dev": true,
1181 | "requires": {
1182 | "color-convert": "^1.9.0"
1183 | }
1184 | },
1185 | "arg": {
1186 | "version": "4.1.3",
1187 | "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz",
1188 | "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA=="
1189 | },
1190 | "array-union": {
1191 | "version": "2.1.0",
1192 | "resolved": "https://registry.npmjs.org/array-union/-/array-union-2.1.0.tgz",
1193 | "integrity": "sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw=="
1194 | },
1195 | "braces": {
1196 | "version": "3.0.2",
1197 | "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz",
1198 | "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==",
1199 | "requires": {
1200 | "fill-range": "^7.0.1"
1201 | }
1202 | },
1203 | "chalk": {
1204 | "version": "2.4.2",
1205 | "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz",
1206 | "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==",
1207 | "dev": true,
1208 | "requires": {
1209 | "ansi-styles": "^3.2.1",
1210 | "escape-string-regexp": "^1.0.5",
1211 | "supports-color": "^5.3.0"
1212 | },
1213 | "dependencies": {
1214 | "has-flag": {
1215 | "version": "3.0.0",
1216 | "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz",
1217 | "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==",
1218 | "dev": true
1219 | },
1220 | "supports-color": {
1221 | "version": "5.5.0",
1222 | "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz",
1223 | "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==",
1224 | "dev": true,
1225 | "requires": {
1226 | "has-flag": "^3.0.0"
1227 | }
1228 | }
1229 | }
1230 | },
1231 | "color-convert": {
1232 | "version": "1.9.3",
1233 | "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz",
1234 | "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==",
1235 | "dev": true,
1236 | "requires": {
1237 | "color-name": "1.1.3"
1238 | }
1239 | },
1240 | "color-name": {
1241 | "version": "1.1.3",
1242 | "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz",
1243 | "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==",
1244 | "dev": true
1245 | },
1246 | "create-require": {
1247 | "version": "1.1.1",
1248 | "resolved": "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz",
1249 | "integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ=="
1250 | },
1251 | "debug": {
1252 | "version": "4.3.4",
1253 | "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz",
1254 | "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==",
1255 | "requires": {
1256 | "ms": "2.1.2"
1257 | }
1258 | },
1259 | "did-you-mean": {
1260 | "version": "0.0.1",
1261 | "resolved": "https://registry.npmjs.org/did-you-mean/-/did-you-mean-0.0.1.tgz",
1262 | "integrity": "sha512-rKxPpbrHr4/u8VMPde6Z3DhbGoXw7kepHZIU2FGs+IU+LKnhEIlw1cx80FZ7fLruJXDyu0slKMai2FhPRZjwxQ==",
1263 | "dev": true,
1264 | "requires": {
1265 | "levenshtein": "*",
1266 | "underscore": "*"
1267 | }
1268 | },
1269 | "diff": {
1270 | "version": "4.0.2",
1271 | "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz",
1272 | "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A=="
1273 | },
1274 | "dir-glob": {
1275 | "version": "3.0.1",
1276 | "resolved": "https://registry.npmjs.org/dir-glob/-/dir-glob-3.0.1.tgz",
1277 | "integrity": "sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==",
1278 | "requires": {
1279 | "path-type": "^4.0.0"
1280 | }
1281 | },
1282 | "escape-string-regexp": {
1283 | "version": "1.0.5",
1284 | "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz",
1285 | "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==",
1286 | "dev": true
1287 | },
1288 | "eslint-config-prettier": {
1289 | "version": "8.5.0",
1290 | "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-8.5.0.tgz",
1291 | "integrity": "sha512-obmWKLUNCnhtQRKc+tmnYuQl0pFU1ibYJQ5BGhTVB08bHe9wC8qUeG7c08dj9XX+AuPj1YSGSQIHl1pnDHZR0Q=="
1292 | },
1293 | "eslint-plugin-prettier": {
1294 | "version": "4.2.1",
1295 | "resolved": "https://registry.npmjs.org/eslint-plugin-prettier/-/eslint-plugin-prettier-4.2.1.tgz",
1296 | "integrity": "sha512-f/0rXLXUt0oFYs8ra4w49wYZBG5GKZpAYsJSm6rnYL5uVDjd+zowwMwVZHnAjf4edNrKpCDYfXDgmRE/Ak7QyQ==",
1297 | "requires": {
1298 | "prettier-linter-helpers": "^1.0.0"
1299 | }
1300 | },
1301 | "eslint-scope": {
1302 | "version": "5.1.1",
1303 | "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.1.1.tgz",
1304 | "integrity": "sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw==",
1305 | "requires": {
1306 | "esrecurse": "^4.3.0",
1307 | "estraverse": "^4.1.1"
1308 | }
1309 | },
1310 | "eslint-utils": {
1311 | "version": "3.0.0",
1312 | "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-3.0.0.tgz",
1313 | "integrity": "sha512-uuQC43IGctw68pJA1RgbQS8/NP7rch6Cwd4j3ZBtgo4/8Flj4eGE7ZYSZRN3iq5pVUv6GPdW5Z1RFleo84uLDA==",
1314 | "requires": {
1315 | "eslint-visitor-keys": "^2.0.0"
1316 | },
1317 | "dependencies": {
1318 | "eslint-visitor-keys": {
1319 | "version": "2.1.0",
1320 | "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-2.1.0.tgz",
1321 | "integrity": "sha512-0rSmRBzXgDzIsD6mGdJgevzgezI534Cer5L/vyMX0kHzT/jiB43jRhd9YUlMGYLQy2zprNmoT8qasCGtY+QaKw=="
1322 | }
1323 | }
1324 | },
1325 | "eslint-visitor-keys": {
1326 | "version": "3.3.0",
1327 | "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.3.0.tgz",
1328 | "integrity": "sha512-mQ+suqKJVyeuwGYHAdjMFqjCyfl8+Ldnxuyp3ldiMBFKkvytrXUZWaiPCEav8qDHKty44bD+qV1IP4T+w+xXRA=="
1329 | },
1330 | "esrecurse": {
1331 | "version": "4.3.0",
1332 | "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz",
1333 | "integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==",
1334 | "requires": {
1335 | "estraverse": "^5.2.0"
1336 | },
1337 | "dependencies": {
1338 | "estraverse": {
1339 | "version": "5.3.0",
1340 | "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz",
1341 | "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA=="
1342 | }
1343 | }
1344 | },
1345 | "estraverse": {
1346 | "version": "4.3.0",
1347 | "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.3.0.tgz",
1348 | "integrity": "sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw=="
1349 | },
1350 | "fast-diff": {
1351 | "version": "1.2.0",
1352 | "resolved": "https://registry.npmjs.org/fast-diff/-/fast-diff-1.2.0.tgz",
1353 | "integrity": "sha512-xJuoT5+L99XlZ8twedaRf6Ax2TgQVxvgZOYoPKqZufmJib0tL2tegPBOZb1pVNgIhlqDlA0eO0c3wBvQcmzx4w=="
1354 | },
1355 | "fast-glob": {
1356 | "version": "3.2.12",
1357 | "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.2.12.tgz",
1358 | "integrity": "sha512-DVj4CQIYYow0BlaelwK1pHl5n5cRSJfM60UA0zK891sVInoPri2Ekj7+e1CT3/3qxXenpI+nBBmQAcJPJgaj4w==",
1359 | "requires": {
1360 | "@nodelib/fs.stat": "^2.0.2",
1361 | "@nodelib/fs.walk": "^1.2.3",
1362 | "glob-parent": "^5.1.2",
1363 | "merge2": "^1.3.0",
1364 | "micromatch": "^4.0.4"
1365 | }
1366 | },
1367 | "fastq": {
1368 | "version": "1.13.0",
1369 | "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.13.0.tgz",
1370 | "integrity": "sha512-YpkpUnK8od0o1hmeSc7UUs/eB/vIPWJYjKck2QKIzAf71Vm1AAQ3EbuZB3g2JIy+pg+ERD0vqI79KyZiB2e2Nw==",
1371 | "requires": {
1372 | "reusify": "^1.0.4"
1373 | }
1374 | },
1375 | "fill-range": {
1376 | "version": "7.0.1",
1377 | "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz",
1378 | "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==",
1379 | "requires": {
1380 | "to-regex-range": "^5.0.1"
1381 | }
1382 | },
1383 | "git-commit-msg-linter": {
1384 | "version": "4.2.1",
1385 | "resolved": "https://registry.npmjs.org/git-commit-msg-linter/-/git-commit-msg-linter-4.2.1.tgz",
1386 | "integrity": "sha512-4iw0N0Sdga5wWN527/Oei6wkQGuWBhUEioonaM3HcaddEP8rYQPApGvfNvCkA+spd0wo59ToK+9DgHaHu1mAqg==",
1387 | "dev": true,
1388 | "requires": {
1389 | "chalk": "^2.4.2",
1390 | "did-you-mean": "^0.0.1",
1391 | "supports-color": "^8.1.1"
1392 | }
1393 | },
1394 | "glob-parent": {
1395 | "version": "5.1.2",
1396 | "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz",
1397 | "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==",
1398 | "requires": {
1399 | "is-glob": "^4.0.1"
1400 | }
1401 | },
1402 | "globby": {
1403 | "version": "11.1.0",
1404 | "resolved": "https://registry.npmjs.org/globby/-/globby-11.1.0.tgz",
1405 | "integrity": "sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==",
1406 | "requires": {
1407 | "array-union": "^2.1.0",
1408 | "dir-glob": "^3.0.1",
1409 | "fast-glob": "^3.2.9",
1410 | "ignore": "^5.2.0",
1411 | "merge2": "^1.4.1",
1412 | "slash": "^3.0.0"
1413 | }
1414 | },
1415 | "has-flag": {
1416 | "version": "4.0.0",
1417 | "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
1418 | "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==",
1419 | "dev": true
1420 | },
1421 | "ignore": {
1422 | "version": "5.2.0",
1423 | "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.2.0.tgz",
1424 | "integrity": "sha512-CmxgYGiEPCLhfLnpPp1MoRmifwEIOgjcHXxOBjv7mY96c+eWScsOP9c112ZyLdWHi0FxHjI+4uVhKYp/gcdRmQ=="
1425 | },
1426 | "is-extglob": {
1427 | "version": "2.1.1",
1428 | "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz",
1429 | "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ=="
1430 | },
1431 | "is-glob": {
1432 | "version": "4.0.3",
1433 | "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz",
1434 | "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==",
1435 | "requires": {
1436 | "is-extglob": "^2.1.1"
1437 | }
1438 | },
1439 | "is-number": {
1440 | "version": "7.0.0",
1441 | "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz",
1442 | "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng=="
1443 | },
1444 | "levenshtein": {
1445 | "version": "1.0.5",
1446 | "resolved": "https://registry.npmjs.org/levenshtein/-/levenshtein-1.0.5.tgz",
1447 | "integrity": "sha512-UQf1nnmxjl7O0+snDXj2YF2r74Gkya8ZpnegrUBYN9tikh2dtxV/ey8e07BO5wwo0i76yjOvbDhFHdcPEiH9aA==",
1448 | "dev": true
1449 | },
1450 | "lru-cache": {
1451 | "version": "6.0.0",
1452 | "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz",
1453 | "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==",
1454 | "requires": {
1455 | "yallist": "^4.0.0"
1456 | }
1457 | },
1458 | "make-error": {
1459 | "version": "1.3.6",
1460 | "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz",
1461 | "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw=="
1462 | },
1463 | "merge2": {
1464 | "version": "1.4.1",
1465 | "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz",
1466 | "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg=="
1467 | },
1468 | "micromatch": {
1469 | "version": "4.0.5",
1470 | "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.5.tgz",
1471 | "integrity": "sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA==",
1472 | "requires": {
1473 | "braces": "^3.0.2",
1474 | "picomatch": "^2.3.1"
1475 | }
1476 | },
1477 | "ms": {
1478 | "version": "2.1.2",
1479 | "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz",
1480 | "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w=="
1481 | },
1482 | "natural-compare-lite": {
1483 | "version": "1.4.0",
1484 | "resolved": "https://registry.npmjs.org/natural-compare-lite/-/natural-compare-lite-1.4.0.tgz",
1485 | "integrity": "sha512-Tj+HTDSJJKaZnfiuw+iaF9skdPpTo2GtEly5JHnWV/hfv2Qj/9RKsGISQtLh2ox3l5EAGw487hnBee0sIJ6v2g=="
1486 | },
1487 | "path-type": {
1488 | "version": "4.0.0",
1489 | "resolved": "https://registry.npmjs.org/path-type/-/path-type-4.0.0.tgz",
1490 | "integrity": "sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw=="
1491 | },
1492 | "picomatch": {
1493 | "version": "2.3.1",
1494 | "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz",
1495 | "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA=="
1496 | },
1497 | "prettier": {
1498 | "version": "2.8.7",
1499 | "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.8.7.tgz",
1500 | "integrity": "sha512-yPngTo3aXUUmyuTjeTUT75txrf+aMh9FiD7q9ZE/i6r0bPb22g4FsE6Y338PQX1bmfy08i9QQCB7/rcUAVntfw==",
1501 | "dev": true
1502 | },
1503 | "prettier-linter-helpers": {
1504 | "version": "1.0.0",
1505 | "resolved": "https://registry.npmjs.org/prettier-linter-helpers/-/prettier-linter-helpers-1.0.0.tgz",
1506 | "integrity": "sha512-GbK2cP9nraSSUF9N2XwUwqfzlAFlMNYYl+ShE/V+H8a9uNl/oUqB1w2EL54Jh0OlyRSd8RfWYJ3coVS4TROP2w==",
1507 | "requires": {
1508 | "fast-diff": "^1.1.2"
1509 | }
1510 | },
1511 | "queue-microtask": {
1512 | "version": "1.2.3",
1513 | "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz",
1514 | "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A=="
1515 | },
1516 | "regexpp": {
1517 | "version": "3.2.0",
1518 | "resolved": "https://registry.npmjs.org/regexpp/-/regexpp-3.2.0.tgz",
1519 | "integrity": "sha512-pq2bWo9mVD43nbts2wGv17XLiNLya+GklZ8kaDLV2Z08gDCsGpnKn9BFMepvWuHCbyVvY7J5o5+BVvoQbmlJLg=="
1520 | },
1521 | "reusify": {
1522 | "version": "1.0.4",
1523 | "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz",
1524 | "integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw=="
1525 | },
1526 | "run-parallel": {
1527 | "version": "1.2.0",
1528 | "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz",
1529 | "integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==",
1530 | "requires": {
1531 | "queue-microtask": "^1.2.2"
1532 | }
1533 | },
1534 | "semver": {
1535 | "version": "7.3.8",
1536 | "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.8.tgz",
1537 | "integrity": "sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A==",
1538 | "requires": {
1539 | "lru-cache": "^6.0.0"
1540 | }
1541 | },
1542 | "slash": {
1543 | "version": "3.0.0",
1544 | "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz",
1545 | "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q=="
1546 | },
1547 | "supports-color": {
1548 | "version": "8.1.1",
1549 | "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz",
1550 | "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==",
1551 | "dev": true,
1552 | "requires": {
1553 | "has-flag": "^4.0.0"
1554 | }
1555 | },
1556 | "to-regex-range": {
1557 | "version": "5.0.1",
1558 | "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz",
1559 | "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==",
1560 | "requires": {
1561 | "is-number": "^7.0.0"
1562 | }
1563 | },
1564 | "ts-node": {
1565 | "version": "10.9.1",
1566 | "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.9.1.tgz",
1567 | "integrity": "sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw==",
1568 | "requires": {
1569 | "@cspotcode/source-map-support": "^0.8.0",
1570 | "@tsconfig/node10": "^1.0.7",
1571 | "@tsconfig/node12": "^1.0.7",
1572 | "@tsconfig/node14": "^1.0.0",
1573 | "@tsconfig/node16": "^1.0.2",
1574 | "acorn": "^8.4.1",
1575 | "acorn-walk": "^8.1.1",
1576 | "arg": "^4.1.0",
1577 | "create-require": "^1.1.0",
1578 | "diff": "^4.0.1",
1579 | "make-error": "^1.1.1",
1580 | "v8-compile-cache-lib": "^3.0.1",
1581 | "yn": "3.1.1"
1582 | },
1583 | "dependencies": {
1584 | "acorn": {
1585 | "version": "8.8.1",
1586 | "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.8.1.tgz",
1587 | "integrity": "sha512-7zFpHzhnqYKrkYdUjF1HI1bzd0VygEGX8lFk4k5zVMqHEoES+P+7TKI+EvLO9WVMJ8eekdO0aDEK044xTXwPPA=="
1588 | }
1589 | }
1590 | },
1591 | "tslib": {
1592 | "version": "1.14.1",
1593 | "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz",
1594 | "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg=="
1595 | },
1596 | "tsutils": {
1597 | "version": "3.21.0",
1598 | "resolved": "https://registry.npmjs.org/tsutils/-/tsutils-3.21.0.tgz",
1599 | "integrity": "sha512-mHKK3iUXL+3UF6xL5k0PEhKRUBKPBCv/+RkEOpjRWxxx27KKRBmmA60A9pgOUvMi8GKhRMPEmjBRPzs2W7O1OA==",
1600 | "requires": {
1601 | "tslib": "^1.8.1"
1602 | }
1603 | },
1604 | "typescript": {
1605 | "version": "4.9.3",
1606 | "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.9.3.tgz",
1607 | "integrity": "sha512-CIfGzTelbKNEnLpLdGFgdyKhG23CKdKgQPOBc+OUNrkJ2vr+KSzsSV5kq5iWhEQbok+quxgGzrAtGWCyU7tHnA=="
1608 | },
1609 | "underscore": {
1610 | "version": "1.13.6",
1611 | "resolved": "https://registry.npmjs.org/underscore/-/underscore-1.13.6.tgz",
1612 | "integrity": "sha512-+A5Sja4HP1M08MaXya7p5LvjuM7K6q/2EaC0+iovj/wOcMsTzMvDFbasi/oSapiwOlt252IqsKqPjCl7huKS0A==",
1613 | "dev": true
1614 | },
1615 | "v8-compile-cache-lib": {
1616 | "version": "3.0.1",
1617 | "resolved": "https://registry.npmjs.org/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz",
1618 | "integrity": "sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg=="
1619 | },
1620 | "yallist": {
1621 | "version": "4.0.0",
1622 | "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz",
1623 | "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A=="
1624 | },
1625 | "yn": {
1626 | "version": "3.1.1",
1627 | "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz",
1628 | "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q=="
1629 | }
1630 | }
1631 | }
1632 |
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "curso-typescript-zero-to-hero",
3 | "version": "1.0.0",
4 | "description": "Curso TypeScript - Zero to Hero!",
5 | "main": "index.js",
6 | "scripts": {
7 | "test": "echo \"Error: no test specified\" && exit 1"
8 | },
9 | "repository": {
10 | "type": "git",
11 | "url": "git+https://github.com/glaucia86/curso-typescript-zero-to-hero.git"
12 | },
13 | "keywords": [],
14 | "author": "",
15 | "license": "ISC",
16 | "bugs": {
17 | "url": "https://github.com/glaucia86/curso-typescript-zero-to-hero/issues"
18 | },
19 | "homepage": "https://github.com/glaucia86/curso-typescript-zero-to-hero#readme",
20 | "dependencies": {
21 | "@typescript-eslint/eslint-plugin": "^5.44.0",
22 | "@typescript-eslint/parser": "^5.44.0",
23 | "eslint-config-prettier": "^8.5.0",
24 | "eslint-plugin-prettier": "^4.2.1",
25 | "ts-node": "^10.9.1",
26 | "typescript": "^4.9.3"
27 | },
28 | "devDependencies": {
29 | "git-commit-msg-linter": "^4.2.1",
30 | "prettier": "2.8.7"
31 | }
32 | }
33 |
--------------------------------------------------------------------------------
/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "target": "ES2019",
4 | "module": "CommonJS",
5 | "lib": ["ESNext", "DOM"],
6 | "outDir": "./dist",
7 | "removeComments": true,
8 | "noEmitOnError": true,
9 | "strict": true,
10 | "esModuleInterop": true,
11 | "skipLibCheck": true,
12 | "forceConsistentCasingInFileNames": true,
13 | "strictNullChecks": false
14 | },
15 | }
16 |
--------------------------------------------------------------------------------