Skip to content

Commit 02a025e

Browse files
kjdelisleKevin Delisle
authored andcommitted
fix(rest): Add index boilerplate
1 parent 8c7f474 commit 02a025e

File tree

2 files changed

+15
-0
lines changed

2 files changed

+15
-0
lines changed

packages/rest/index.d.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
// Copyright IBM Corp. 2017. All Rights Reserved.
2+
// Node module: @loopback/rest
3+
// This file is licensed under the MIT License.
4+
// License text available at https://opensource.org/licenses/MIT
5+
6+
export * from './lib';

packages/rest/index.js

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
// Copyright IBM Corp. 2017. All Rights Reserved.
2+
// Node module: @loopback/rest
3+
// This file is licensed under the MIT License.
4+
// License text available at https://opensource.org/licenses/MIT
5+
6+
const nodeMajorVersion = +process.versions.node.split('.')[0];
7+
module.exports = nodeMajorVersion >= 7 ?
8+
require('./lib') :
9+
require('./lib6');

0 commit comments

Comments
 (0)