A Simple Project With TypeScript & NodeJs



Getting Started

mkdir read-excel
cd .\read-excel\
npm init -y

NOTE: npm init -y skips the wizard and attempts to pre-populate the details in the packa.json file

The output from npm init -y
npm i -D commitizen commitlint cz-conventional-changelog eslint @typescript-eslint/eslint-plugin eslint-config-prettier eslint-plugin-prettier ts-node
"config": {
"commitizen": {
"path": "./node_modules/cz-conventional-changelog"
module.exports = {
parser: '@typescript-eslint/parser',
parserOptions: {
project: 'tsconfig.json',
sourceType: 'module',
plugins: ['@typescript-eslint/eslint-plugin'],
extends: [
root: true,
env: {
node: true,
jest: true,
ignorePatterns: ['.eslintrc.js', 'graphql.ts'],
rules: {
'@typescript-eslint/interface-name-prefix': 'off',
'@typescript-eslint/explicit-function-return-type': 'off',
'@typescript-eslint/explicit-module-boundary-types': 'off',
'@typescript-eslint/no-explicit-any': 'off',
"singleQuote": true,
"trailingComma": "all",
"endOfLine": "auto"
const helloWorld = () => {
console.log('Hellow, World')

  "scripts": {
"start": "ts-node src/index.ts"
Output from running npm run start
# ignore the node_modules folder.
# Keep environment variables out of version control


# Dist

# coverage

# documentation

# ignore any temp documents
git init
git add .
Output in a PowerShell terminal for git commands
Enter the details in the cz wizard like this
GitHub repo add code instructions
git remote add origin git@github.com:<USERNAME>/read-excel.git
git push -u origin main
Output from a GitHub push
Using git flow init command
git push --set-upstream origin develop
Github repo
  "scripts": {
"eslint": "eslint src/**",
"start": "ts-node src/index.ts"
"compilerOptions": {
"module": "commonjs",
"declaration": true,
"removeComments": true,
"emitDecoratorMetadata": true,
"experimentalDecorators": true,
"allowSyntheticDefaultImports": true,
"target": "es2017",
"sourceMap": true,
"outDir": "./dist",
"baseUrl": "./",
"incremental": true,
"skipLibCheck": true,
"resolveJsonModule": true,
"lib": ["esnext"],
"esModuleInterop": true
Post lint errors
  "scripts": {
"eslint": "eslint src/** --fix",
"start": "ts-node src/index.ts"
git add .
Adding the git-cz details



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Andrew Allison

15 Years of Professionally putting characters in places that produces great software systems. A life time of hacking on computers.