Skip to content

Commit 22a106c

Browse files
authored
Merge pull request #72 from MailOnline/fix/build
fix: fix build include .tsx files in output
2 parents 35290bf + e9860c4 commit 22a106c

File tree

3 files changed

+14
-12
lines changed

3 files changed

+14
-12
lines changed

build/gulpfile.js

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -12,20 +12,22 @@ const ignore = [
1212
];
1313

1414
gulp.task('build-ts', () => {
15-
return gulp.src([
16-
'../src/**/*.ts',
17-
'../src/**/*.tsx',
18-
...ignore
19-
]).pipe(ts({
20-
...tsConfig.compilerOptions,
21-
target: 'es5',
22-
module: 'commonjs'
23-
})).pipe(gulp.dest('../lib'));
15+
return gulp
16+
.src([
17+
'../src/**/*.ts',
18+
...ignore
19+
])
20+
.pipe(ts({
21+
...tsConfig.compilerOptions,
22+
target: 'es5',
23+
module: 'commonjs'
24+
}))
25+
.pipe(gulp.dest('../lib'));
2426
});
2527

2628
gulp.task('build-modules', () => {
2729
return gulp.src([
28-
'../src/**/*.ts',
30+
'../src/**/*.{ts,tsx}',
2931
...ignore
3032
]).pipe(ts({
3133
...tsConfig.compilerOptions,

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "libreact",
3-
"version": "1.5.0",
3+
"version": "1.6.1",
44
"description": "React standard library",
55
"main": "lib/index.js",
66
"repository": {

src/ViewportSensor/index.tsx renamed to src/ViewportSensor/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ if (!(window as any).IntersectionObserver) {
1313
}
1414

1515
export const ViewportSensor: React.StatelessComponent<IViewportObserverSensorProps> = (props) => {
16-
return <Sensor {...props} />
16+
return h(Sensor, props);
1717
};
1818

1919
const wrapper = (Comp, propName, props, state) =>

0 commit comments

Comments
 (0)