Skip to content

Commit 70c1bbe

Browse files
docs: add preload script testing tutorial (#2812)
1 parent 5ccacbe commit 70c1bbe

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

docs/content/docs/developers/troubleshooting.mdx

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,4 +33,14 @@ You may have to delete cookies to clear the authentication state.
3333
If you encounter issues such as "Column not found" error, your database may be out of sync with the schema. There are 2 things to try to get it back in sync:
3434

3535
1. Run `bun db:push` to push the schema to the database. If there are conflicts, you can try step 2.
36-
2. Run `bun db:reset` to fully reset the database and re-run the migrations. WARNING: This will delete all data in the database.
36+
2. Run `bun db:reset` to fully reset the database and re-run the migrations. WARNING: This will delete all data in the database.
37+
38+
### Testing the Preload Script
39+
40+
If you want to update the preload script and test it with Onlook, follow these steps:
41+
42+
1. Run bun `bun run dev` from the root of the project.
43+
2. Copy the file `apps/web/client/public/onlook-preload-script.js` into to `public/onlook-preload-script.js` in the code tab in onlook or the codesandbox interface.
44+
3. Refresh the localhost tab. You should now be able to test the preload script.
45+
46+
If you want to update the preload script and test any changes, you need to refresh the localhost tab.

0 commit comments

Comments
 (0)