-
Notifications
You must be signed in to change notification settings - Fork 300
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
more work to support subapp inlining subapp (#1524)
- Loading branch information
Showing
36 changed files
with
957 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
"use strict"; | ||
|
||
const { reduxBundlerLoadSubApp } = require("../../lib/redux-bundler"); | ||
|
||
describe("redux-bundler load subapp", function() { | ||
it("should initialize reduxCreateStore if it's not provided", () => { | ||
const subapp = reduxBundlerLoadSubApp({ | ||
name: `test-${Date.now()}-1` | ||
}); | ||
expect(subapp.__redux).to.equal(true); | ||
expect(subapp._genReduxCreateStore).to.equal("subapp"); | ||
expect(subapp.reduxCreateStore).to.be.ok; | ||
}); | ||
|
||
it("should keep user provided reduxCreateStore", () => { | ||
const subapp = reduxBundlerLoadSubApp({ | ||
name: `test-${Date.now()}-2`, | ||
reduxCreateStore: () => {} | ||
}); | ||
expect(subapp.__redux).to.equal(true); | ||
expect(subapp._genReduxCreateStore).to.equal(undefined); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
# Browsers that we support | ||
last 2 versions | ||
ie >= 11 | ||
> 5% |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
root = true | ||
|
||
[*] | ||
indent_style = space | ||
indent_size = 2 | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true | ||
|
||
[*.md] | ||
trim_trailing_whitespace = false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
var path = require("path"); | ||
var archetype = require("electrode-archetype-react-app/config/archetype"); | ||
var archetypeEslint = path.join(archetype.config.eslint, ".eslintrc-react"); | ||
|
||
function dotify(p) { | ||
return path.isAbsolute(p) ? p : "." + path.sep + p; | ||
} | ||
|
||
module.exports = { | ||
extends: dotify(path.relative(__dirname, archetypeEslint)) | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* text=auto |
Oops, something went wrong.