-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Uses new @sajari/sdk-react v2.3.1 * Adds localization * Removes css file from dist * Adds styling and theming to config object * Adds inputMode member to config object, allows for typeahead/InstantSearch to be enabled JRA AA-15 Change-Id: I42400e96edc8e80b47f7062f31e64a8ccfeeccb9 Reviewed-on: https://review.sajari.com/182 Reviewed-by: Trent Billington <[email protected]> Reviewed-by: David Howden <[email protected]> Tested-by: David Howden <[email protected]>
- Loading branch information
Showing
50 changed files
with
7,228 additions
and
19,432 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 was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -1,53 +1,27 @@ | ||
const { resolve } = require("path"); | ||
|
||
const ExtractTextPlugin = require("extract-text-webpack-plugin"); | ||
|
||
const VERSION = require("../package.json").version; | ||
const VERSION = require("../package.json").version.split("."); | ||
const [VERSION_MAJOR, VERSION_MINOR] = VERSION; | ||
|
||
module.exports = { | ||
target: "web", | ||
entry: { | ||
"website-search": resolve(__dirname, "../src/index.js") | ||
"website-search": resolve(__dirname, "../src/index.ts") | ||
}, | ||
output: { | ||
path: resolve(__dirname, "../dist"), | ||
filename: `[name]-${VERSION}.js` | ||
filename: `[name]-${VERSION_MAJOR}.${VERSION_MINOR}.js` | ||
}, | ||
module: { | ||
rules: [ | ||
{ | ||
test: /\.css$/, | ||
use: ExtractTextPlugin.extract({ | ||
fallback: "style-loader", | ||
use: { | ||
loader: "postcss-loader", | ||
options: { | ||
config: { | ||
path: resolve(__dirname, "./postcss.config.js") | ||
} | ||
} | ||
} | ||
}) | ||
}, | ||
{ | ||
test: /\.js$/, | ||
test: [/\.js$/, /\.tsx?/], | ||
exclude: [/node_modules/], | ||
use: ["babel-loader"] | ||
use: "babel-loader" | ||
} | ||
] | ||
}, | ||
plugins: [new ExtractTextPlugin(`[name]-${VERSION}.css`)], | ||
resolve: { | ||
extensions: [".js"], | ||
alias: { | ||
react: "preact-compat", | ||
"react-dom": "preact-compat", | ||
"create-react-class": "preact-compat/lib/create-react-class" | ||
|
||
// So we load the ES6 module versions, without having to rewrite our import | ||
// statements. | ||
// sajari$: resolve(__dirname, "../node_modules/sajari/dist.es/main.js"), | ||
// "sajari-react": resolve(__dirname, "../node_modules/sajari-react/es") | ||
} | ||
extensions: [".js", ".ts", ".tsx"] | ||
} | ||
}; |
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
Oops, something went wrong.