We'll start by installing the AWS Cloud Development Kit.
- npm install -g aws-cdk
-g stands for global (meaning that once installed, this package will be available anywhere on your computer)
π Throughout the course, Hanii will use both yarn and npm package mangers, and it's really up to you to decide which one to use, as both work fine.
Verify thatcdk was installed.
- cdk --version
Initialize a new cdk project.
- cdk init
BASH
* sample-app: Example CDK Application with some constructsββ cdk init sample-app --language=[csharp|fsharp|java|javascript|python|typescript]
We are going to choose the sample app, typescript template:
- cdk init sample-app --language=typescript
This will create a bunch of files with the following directory structure (note that I'm displaying files just one level deep here):
BASH
.βββ .gitβββ .gitignoreβββ .npmignoreβββ README.mdβββ binβββ cdk.jsonβββ jest.config.jsβββ libβββ node_modulesβββ package-lock.jsonβββ package.jsonβββ testβββ tsconfig.json
π You can run tree -la 1 to display the tree.
Β Β PreviousΒ Β Β Β Β Next