Skip to content

Commit 7955295

Browse files
authored
Merge pull request #37 from ahnv/typescript
IMAGEKIT-56 Typescript support
2 parents fdc49af + ec243e5 commit 7955295

34 files changed

+7186
-5438
lines changed

.babelrc

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11
{
2-
"presets": [
3-
[
4-
"@babel/env",
5-
{
6-
"modules": false
7-
}
8-
]
2+
"plugins": ["@babel/plugin-proposal-class-properties"],
3+
"presets": [
4+
"@babel/preset-typescript",
5+
[
6+
"@babel/env",
7+
{
8+
"targets": "> 0.25%, not dead"
9+
}
910
]
10-
}
11+
]
12+
}

.github/workflows/nodejs.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
name: Node CI
22

3-
on: [push]
3+
on:
4+
push:
5+
pull_request:
6+
branches:
7+
- master
48

59
jobs:
610
build:

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,5 @@ samples/sample-app/node_modules/*
66
dist
77
.nyc_output
88
coverage.lcov
9-
coverage
9+
coverage
10+
out-tsc

.mocharc.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"coverage": true,
3+
"require": ["esm", "./babel-register.js"],
4+
"exit": true,
5+
"timeout": "40000"
6+
}

.nycrc.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"reporter": ["lcov", "text"],
3+
"exclude": ["babel-register.js", "test"],
4+
"include": ["src"]
5+
}

babel-register.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
require("@babel/register")({ extensions: ['.js', '.jsx', '.ts', '.tsx'] });

0 commit comments

Comments
 (0)