Skip to content

Commit 0e9e8d1

Browse files
committed
fix(universal): remove need to add KeyboardEvent hack to server.ts
1 parent 0faa8ef commit 0e9e8d1

File tree

5 files changed

+4
-11
lines changed

5 files changed

+4
-11
lines changed

README.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ https://mattlewis92.github.io/angular-calendar/
2525
<a href="https://github.com/sponsors/mattlewis92">Become a gold or platinum sponsor<a> and get your logo on this README on Github with a link to your site.<br><br>
2626

2727
<a href="https://runbox.com/" target="_blank"><img src="https://raw.githubusercontent.com/runbox/runbox7/master/src/assets/runbox7_blue_dark.png" width="288"></a>
28+
2829
</div>
2930

3031
## Table of contents
@@ -78,9 +79,9 @@ import { adapterFactory } from 'angular-calendar/date-adapters/date-fns';
7879
BrowserAnimationsModule,
7980
CalendarModule.forRoot({
8081
provide: DateAdapter,
81-
useFactory: adapterFactory
82-
})
83-
]
82+
useFactory: adapterFactory,
83+
}),
84+
],
8485
})
8586
export class MyModule {}
8687
```
@@ -111,7 +112,6 @@ Yes. For universal to work though, you will need to add this near the top of you
111112

112113
```ts
113114
global['window'] = {};
114-
global['KeyboardEvent'] = null;
115115
```
116116

117117
### What major versions of angular does this library support?

build-tool-examples/angular-cli/server.ts

-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ import * as express from 'express';
2121
import {join} from 'path';
2222

2323
global['window'] = {};
24-
global['KeyboardEvent'] = null;
2524

2625
// Express server
2726
const app = express();

build-tool-examples/angular-cli/tsconfig.json

-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
"sourceMap": true,
99
"declaration": false,
1010
"moduleResolution": "node",
11-
"emitDecoratorMetadata": true,
1211
"experimentalDecorators": true,
1312
"target": "es2015",
1413
"typeRoots": [

projects/angular-calendar/tsconfig.lib.json

-4
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,8 @@
44
"outDir": "../../out-tsc/lib",
55
"target": "es2015",
66
"module": "es2015",
7-
"moduleResolution": "node",
87
"declaration": true,
9-
"sourceMap": true,
108
"inlineSources": true,
11-
"emitDecoratorMetadata": true,
12-
"experimentalDecorators": true,
139
"importHelpers": true,
1410
"types": [],
1511
"lib": [

tsconfig.json

-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
"declaration": false,
88
"module": "esnext",
99
"moduleResolution": "node",
10-
"emitDecoratorMetadata": true,
1110
"experimentalDecorators": true,
1211
"target": "es2015",
1312
"typeRoots": [

0 commit comments

Comments
 (0)