Skip to content

Commit

Permalink
Merge pull request #583 from RoXuS/enableTypescriptEsm
Browse files Browse the repository at this point in the history
Enable typescript on esm build
  • Loading branch information
wheresrhys committed Jul 25, 2020
2 parents b9b0b03 + b423d84 commit 55fa469
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Makefile
Expand Up @@ -48,6 +48,8 @@ build: transpile
cp -r src/* cjs
rollup -c rollup.config.js
echo '{"type": "module"}' > esm/package.json
cp types/index.d.ts esm/client.d.ts
cp types/index.d.ts esm/server.d.ts

docs:
cd docs; jekyll serve build --watch
Expand Down
5 changes: 5 additions & 0 deletions types/index.d.ts
Expand Up @@ -662,3 +662,8 @@ declare namespace fetchMock {

declare var fetchMock: fetchMock.FetchMockStatic;
export = fetchMock;

declare module 'fetch-mock/esm/client' {
const fetchMock: fetchMock.FetchMockStatic;
export default fetchMock;
}

0 comments on commit 55fa469

Please sign in to comment.