Skip to content

Commit

Permalink
fix: prettier fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
atanasster committed Oct 7, 2020
1 parent 4898141 commit cadc70b
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 4 deletions.
3 changes: 2 additions & 1 deletion core/core/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,5 @@ export type SetControlValueFn = (
) => void;
export type ClickControlFn = (storyId: string, propertyName: string) => void;

export const normalizePath = (fillePath: string) => process.platform === 'win32' ? fillePath.replace(/\\/g, '\\\\') : fillePath;
export const normalizePath = (fillePath: string) =>
process.platform === 'win32' ? fillePath.replace(/\\/g, '\\\\') : fillePath;
1 change: 0 additions & 1 deletion core/loader/src/replaceSource.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ export const replaceSource = (
config: BuildConfiguration | undefined,
hashKey: string,
) => {

const imports = `
const configJSON = ${
Expand Down
2 changes: 1 addition & 1 deletion core/store/src/webpack/loader.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { loader } from 'webpack';
import { getOptions } from 'loader-utils';
import { normalizePath } from '@component-controls/core';
import { normalizePath } from '@component-controls/core';

module.exports = function(content: string) {
const context = (this as unknown) as loader.LoaderContext;
Expand Down
4 changes: 3 additions & 1 deletion core/store/src/webpack/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,9 @@ export class StorePlugin {

private installStoreLoader(compiler: webpack.Compiler) {
const nmrp = new webpack.NormalModuleReplacementPlugin(
new RegExp(normalizePath(path.resolve(__dirname, '../controls-store.js'))),
new RegExp(
normalizePath(path.resolve(__dirname, '../controls-store.js')),
),
(resource: any) => {
if (resource.resource) {
resource.loaders.push({
Expand Down

0 comments on commit cadc70b

Please sign in to comment.