Skip to content

Commit

Permalink
fix: reboot the project (#46)
Browse files Browse the repository at this point in the history
* chore: install project with latest pnpm
* fix(blast-api): patch color module
* fix(blast-runtime): patch self and fix react-devtools connection
* docs: update README
  • Loading branch information
Yukaii authored May 5, 2024
1 parent b7aa032 commit c709183
Show file tree
Hide file tree
Showing 11 changed files with 11,417 additions and 8,972 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ Just run:
pnpm react-devtools
```

And start the application. It should automatically connect to the React DevTools.
Then start the application(The devtool must be run before the application started). It should automatically connect to the React DevTools.

![react-devtools](./docs/media/react_dev_tools.png)

Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"lint": "eslint .",
"start:client": "pnpm --filter blast run start",
"test": "pnpm run test",
"cli": "pnpm --filter cli run run"
"cli": "pnpm --filter cli run start"
},
"jest": {
"testEnvironment": "node",
Expand Down Expand Up @@ -63,6 +63,6 @@
},
"engines": {
"node": ">=18.0.0",
"pnpm": "==7 <8"
"pnpm": ">8"
}
}
14 changes: 14 additions & 0 deletions packages/blast-api/src/Color.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import { type Color as RColor } from "raycast-original";

export const Color = {
Blue: "raycast-blue",
Green: "raycast-green",
Magenta: "raycast-magenta",
Orange: "raycast-orange",
Purple: "raycast-purple",
Red: "raycast-red",
Yellow: "raycast-yellow",
PrimaryText: "raycast-primary-text",
SecondaryText: "raycast-secondary-text",
} as const as unknown as RColor

3 changes: 1 addition & 2 deletions packages/blast-api/src/Form/index.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import { Form as RForm } from "raycast-original";

import { ElementTypes } from "@blastlauncher/renderer/src";
import { createDebug } from "@blastlauncher/utils/src";
import { Form as RForm } from "raycast-original";
import { FunctionComponent, createContext, useCallback, useContext, useState } from "react";

import { TextField } from "./TextField";
Expand Down
1 change: 1 addition & 0 deletions packages/blast-api/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ export { Icon } from "./Icon";
export { WsContext, WsServerProvider, useWsServer } from "./internal";
export * from './environment'
export { LaunchType } from './LaunchType'
export * from './Color';
9 changes: 5 additions & 4 deletions packages/blast-cli/build.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
/* eslint-disable @typescript-eslint/no-var-requires */
const esbuild = require("esbuild");
const { nodeExternalsPlugin } = require("esbuild-node-externals");
import { build } from "esbuild";
import { nodeExternalsPlugin } from "esbuild-node-externals";

esbuild.build({
build({
entryPoints: ["index.js"],
bundle: true,
platform: "node",
outfile: "dist/index.cjs",
format: 'esm',
outfile: "dist/index.mjs",
plugins: [
nodeExternalsPlugin({
allowList: ["tempy"],
Expand Down
2 changes: 1 addition & 1 deletion packages/blast-cli/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ class PackageVersionHelper {

return Object.keys(res.versions);
} catch (e) {
// pacakge not found
// package not found
return null;
}
}
Expand Down
8 changes: 5 additions & 3 deletions packages/blast-cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,16 @@
"name": "@blastlauncher/cli",
"version": "1.0.5",
"description": "Blast CLI Tools",
"main": "dist/index.cjs",
"type": "module",
"main": "dist/index.mjs",
"scripts": {
"build": "node build.js",
"prepublishOnly": "npm run build",
"package": "pkg ."
"package": "pkg .",
"start": "node dist/index.mjs"
},
"bin": {
"blast": "dist/index.cjs"
"blast": "dist/index.mjs"
},
"dependencies": {
"commander": "^10.0.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/blast-runtime/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"eval": "^0.1.8",
"node-fetch": "^2.6.8",
"react": "^18.2.0",
"react-devtools-core": "^4.27.1",
"react-devtools-core": "5.1.0",
"websocket": "^1.0.34"
},
"devDependencies": {
Expand Down
1 change: 1 addition & 0 deletions packages/blast-runtime/src/utils/window.js
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
global.window = globalThis;
global.self = globalThis;
Loading

0 comments on commit c709183

Please sign in to comment.