Skip to content

Commit 1a50ee2

Browse files
committed
Add additional test for TypeStrong#102
1 parent 8ba2764 commit 1a50ee2

File tree

6 files changed

+102
-0
lines changed

6 files changed

+102
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
/******/ (function(modules) { // webpackBootstrap
2+
/******/ // The module cache
3+
/******/ var installedModules = {};
4+
5+
/******/ // The require function
6+
/******/ function __webpack_require__(moduleId) {
7+
8+
/******/ // Check if module is in cache
9+
/******/ if(installedModules[moduleId])
10+
/******/ return installedModules[moduleId].exports;
11+
12+
/******/ // Create a new module (and put it into the cache)
13+
/******/ var module = installedModules[moduleId] = {
14+
/******/ exports: {},
15+
/******/ id: moduleId,
16+
/******/ loaded: false
17+
/******/ };
18+
19+
/******/ // Execute the module function
20+
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
21+
22+
/******/ // Flag the module as loaded
23+
/******/ module.loaded = true;
24+
25+
/******/ // Return the exports of the module
26+
/******/ return module.exports;
27+
/******/ }
28+
29+
30+
/******/ // expose the modules object (__webpack_modules__)
31+
/******/ __webpack_require__.m = modules;
32+
33+
/******/ // expose the module cache
34+
/******/ __webpack_require__.c = installedModules;
35+
36+
/******/ // __webpack_public_path__
37+
/******/ __webpack_require__.p = "";
38+
39+
/******/ // Load entry module and return exports
40+
/******/ return __webpack_require__(0);
41+
/******/ })
42+
/************************************************************************/
43+
/******/ ([
44+
/* 0 */
45+
/***/ function(module, exports) {
46+
47+
"use strict";
48+
49+
Object.defineProperty(exports, "__esModule", {
50+
value: true
51+
});
52+
53+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
54+
55+
var BaseComponent = function BaseComponent() {
56+
_classCallCheck(this, BaseComponent);
57+
};
58+
59+
exports.BaseComponent = BaseComponent;
60+
61+
/***/ }
62+
/******/ ]);
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
Asset Size Chunks Chunk Names
2+
bundle.js 1.76 kB 0 [emitted] main
3+
chunk {0} bundle.js (main) 365 bytes [rendered]
4+
[0] ./.test/es6resolveParent/index.tsx 365 bytes {0} [built]

test/es6resolveParent/index.tsx

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
import submodule from './submodule/index';
2+
3+
export class BaseComponent {}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
import { BaseComponent } from '../index';
2+
3+
class Component extends BaseComponent {}
4+
5+
export default 'foo';

test/es6resolveParent/tsconfig.json

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{
2+
"compilerOptions": {
3+
"target": "es6",
4+
"moduleResolution": "node",
5+
"jsx": "react"
6+
},
7+
"files": [
8+
]
9+
}
+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
var path = require('path')
2+
3+
module.exports = {
4+
entry: './index',
5+
output: {
6+
filename: 'bundle.js'
7+
},
8+
resolve: {
9+
extensions: ['', '.ts', '.tsx', '.js']
10+
},
11+
module: {
12+
loaders: [
13+
{ test: /\.tsx?$/, loader: 'babel-loader!ts-loader' }
14+
]
15+
}
16+
}
17+
18+
// for test harness purposes only, you would not need this in a normal project
19+
module.exports.resolveLoader = { alias: { 'ts-loader': require('path').join(__dirname, "../../index.js") } }

0 commit comments

Comments
 (0)