Skip to content

Commit

Permalink
chore: update shared-helpers package to use index.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
adamviktora committed Nov 13, 2024
1 parent ac04c82 commit 1f97fe7
Show file tree
Hide file tree
Showing 9 changed files with 14 additions and 9 deletions.
4 changes: 2 additions & 2 deletions packages/class-name-updater/src/classNameUpdate.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { sync } from "glob";
import { readFileSync, writeFileSync } from "fs";
import { join } from "path";
import { isDir } from "shared-helpers/dist/utils";
import { printDiff } from "shared-helpers/dist/printDiff";
import { isDir } from "shared-helpers";
import { printDiff } from "shared-helpers";

export async function classNameUpdate(
globTarget: string,
Expand Down
2 changes: 1 addition & 1 deletion packages/class-name-updater/src/cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { join } from "path";
import { Command } from "commander";
const program = new Command();

import { isDir } from "shared-helpers/dist/utils";
import { isDir } from "shared-helpers";
import { classNameUpdate } from "./classNameUpdate";

program
Expand Down
2 changes: 1 addition & 1 deletion packages/css-vars-updater/src/cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { Command } from "commander";
const program = new Command();
import inquirer from "inquirer";

import { isDir } from "shared-helpers/dist/utils";
import { isDir } from "shared-helpers";
import { cssVarsUpdate } from "./cssVarsUpdate";
import { Answers } from "./answers";

Expand Down
4 changes: 2 additions & 2 deletions packages/css-vars-updater/src/cssVarsUpdate.ts
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
import { sync } from "glob";
import { readFileSync, writeFileSync } from "fs";
import { join } from "path";
import { isDir } from "shared-helpers/dist/utils";
import { isDir } from "shared-helpers";
// import { printDiff } from "../../../helpers/printDiff";
import {
globalNonColorCssVarNamesMap,
oldCssVarNames,
oldGlobalColorCssVarNames,
oldGlobalNonColorCssVarNames,
v6DirectionCssVars,
} from "shared-helpers/dist/tokenLists";
} from "shared-helpers";
import { Answers } from "./answers";
import { getDirectionMap } from "./directionalStyles";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import {
getImportPath,
} from "../../helpers";
import { Identifier, ImportSpecifier } from "estree-jsx";
import { tokensToPrefixWithT } from "shared-helpers/dist/tokenLists";
import { tokensToPrefixWithT } from "shared-helpers";

module.exports = {
meta: { fixable: "code" },
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import {
globalNonColorCssVarNamesMap,
oldGlobalColorCssVarNames,
oldGlobalColorTokens,
} from "shared-helpers/dist/tokenLists";
} from "shared-helpers";

module.exports = {
meta: { fixable: "code" },
Expand Down
3 changes: 3 additions & 0 deletions packages/shared-helpers/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
"name": "shared-helpers",
"version": "1.0.0",
"description": "Shared helpers for the monorepo",
"main": "./dist/index.js",
"module": "./dist/index.js",
"types": "./dist/index.d.ts",
"scripts": {
"build": "tsc --build --verbose ./tsconfig.json",
"clean": "rimraf ./dist"
Expand Down
3 changes: 3 additions & 0 deletions packages/shared-helpers/src/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
export * from "./tokenLists";
export * from "./printDiff";
export * from "./utils";
1 change: 0 additions & 1 deletion packages/shared-helpers/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"module": "CommonJS",
"outDir": "./dist"
},
"include": ["src/**/*"],
Expand Down

0 comments on commit 1f97fe7

Please sign in to comment.