* add logic to remember last route
* add default redirect
* move logic to index page
* Simplify logs page redirect logic
* missing }
* fix wrong }
* wait 2s for page to redirect
* use latest version in local studio cli test
* rm timeouts looks like it takes longer in ci
* Clean up
* Fix broken commands
---------
Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
* Set up E2E tests for staging
* update
* Update
* Update .env.staging.example
* Fix node modules
* Fix
* Attempt to swap local-studio-tests to use the new studio-tests directory
* Omit storage state if running tests for local self host
* Fix test:local command
* Deprecate local-studio-test folder
* Rename local studio tests GH action to E2E test
* Fix some missing and duplicate dependencies.
* Fix the types for jest in ai-commands package.
* Replace all npm commands with pnpm. Add pnpm files and workspace links.
* Fix rimraf to work with pnpm.
* Refactor the github actions to work with pnpm.
* Delete package-lock.json.
* Fix the tailwind configs to not include node_modules.
* Fix random files.
* Add preinstall scripts to all packages.
* Fix the Dockerfile to work with pnpm.
* Update the DEVELOPERS documentation.
Docs lint errors can make it into master through a race condition:
- PR with lint configuration changes is made
- Separately, a PR that is incompatible with the new configuration (but _is_ compatible with the old one) is merged
This can be annoying for downstream PRs, so lint post-merge, and create a PR with auto-fixes if possible.
PR to start introducing Linter V2!
Primary improvements from this linter:
Better parsing of MDX (fewer false positives)
More flexibility
And suggested autofixes! (see auto-generated PR comment below for how that works)
Turning this on for only a small portion of the repo at first to avoid an avalanche of alerts, will slowly expand from there.
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
When a troubleshooting entry is created or updated in this repo, sync it to GitHub. This creates a new troubleshooting discussion if one does not exist, and updates the content on an existing troubleshooting discussion if it has changed.
To preserve the connections between GitHub discussions and Markdown files, record the discussion ID and URL to the database. The database ID is then written to the Markdown file, and a new PR is generated to commit the new Markdown with ID.
There is currently no mechanism to delete outdated discussions. That will be a follow-up.
Add the ability to embed code samples from GitHub into tutorials, so we can have a single source of truth for the source code.
Introduces the <$CodeSample /> syntax, which is a special syntax and not a real React component (see the directives/README.md for why on earth I did it this way -- in this specific case, CodeHike adjusts the MDX syntax tree before it gets compiled, and we need to adjust it ourselves before CodeHike sees it, so we need to get down to the level of manipulating the AST in order to make this work with CodeHike).
Adjusted one of the example tutorials to use this new feature as a test.
Migrates client SDK References to App Router. (Management and CLI API references aren't migrated yet, nor are self-hosting config references.)
Some notes:
Big changes to the way crawler pages are built and individual section URLs (e.g., javascript/select) are served. All of these used to be SSG-generated pages, but the number of heavy pages was just too much to handle -- slow as molasses and my laptop sounded like it was taking off, and CI sometimes refuses to build it all at all.
Tried various tricks with caching and pre-generating data but no dice.
So I changed to only building one copy of each SDK+version page, then serving the sub-URLs through a response rewrite. That's for the actual user-visible pages.
For the bot pages, each sub-URL needs to be its own page, but prebuilding it doesn't work, and rendering on demand from React components is too slow (looking for super-fast response here for SEO). Instead I changed to using an API route that serves very minimal, hand-crafted HTML. It looks ugly, but it's purely for the search bots.
You can test what bots see by running curl --user-agent "Mozilla/5.0 (iPhone; CPU iPhone OS 6_0 like Mac OS X) AppleWebKit/536.26 (KHTML, like Gecko) Version/6.0 Mobile/10A5376e Safari/8536.25 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)" <URL_OF_PAGE>
Also added some smoke tests to run against prod for the crawler routes, since we don't keep an eye on those regularly, and Vercel config changes could surprise-break them. Tested the meta images on Open Graph and all seems to work fine.
With this approach, full production builds are really fast: ~5 minutes
Starts using the new type spec handling, which is better at finding params automatically, so I could remove some of the manually written ones from the spec files.
We don't need this for migration pushes since the Supabase integration will do
it instead. Removing it makes this action less brittle since embedding updates
get blocked on CLI problems.
* Don't create a new image whenever a new tag is published on supabase/supabase.
* No need for an input when triggering a new build.
* Enable the latest tag for all pushes.
* Add an API page for run-lints endpoint.
* Fix the playwright test.
* Make the check mandatory in the github action.
* Fix a console.log.
* Use a more stable way of waiting for buttons before clicking them.
* Add helper method for dismissing toasts.
* Wait for the other toast.
* Try and fix the flakiness of the toasts.
* Minor fix.
* Upload artifacts at the end of the github action run.
* Fix yaml stuff.
* Use the newer action for uploading. Shorten the retention period to 7 days.
* Add waitForResponse for the entity types API call.
* snapshot.
* Wait for the page to be loaded.
* Make the timeout bigger when waiting for response.
* Try to fix the timeouts.
* Minor restructuring of the test.
* Add another test and few minor todo tests.
* Fix the table names.
* Don't render hcaptcha in test mode.
* Expand the test to include sorting and filtering.
* Add a test for checking if the other schemas are can be listed.
* Make the sort popover button more stable.
* Fix a unused forward ref in the NavMenuItem component.
* Don't render the Toaster container when in test mode.
* Simplify starting the dev server when testing.
* Fix all inputs to have proper test ids.
* Fix the command for testing.
Need a fetch-depth 0 in order to preserve commit dates within GitHub
Actions, otherwise a shallow fetch will use the current date as the
commit date, which renders this entire flow useless.
Keeps track of fine-grained (per section) edit times for docs content.
Once daily, a GitHub Action runs that:
- Checks whether content hashes have changed for each section
- Updates the table that tracks content edit times if the hashes have changed
Note: The cron job isn't scheduled yet. I'll run the Action manually a few times to validate it, then turn it on in another PR.
Introduces the first (very small) slice of the new command menu as a `ui-pattern`.
This slice just handles state for available commands. It isn't hooked up to anything yet.
* Try to fix the prettier github action.
* Revert "Try to fix the prettier github action."
This reverts commit 3a3fbe51e17e9b0b33f9e4ca332d9b40e90e1508.
* Fix the prettier dependency in package-lock.json.
* Run prettier format over the whole repo.
* Revert "Fix the prettier dependency in package-lock.json."
This reverts commit 8c6b24190755a1f5df8681ffc1f339a97f02076e.
* Revert the prettier format changes.
* Add a command for checking prettier. Use it in the github action. Use npm ci in the github action.
* Fix another accidental formatting.
* fix: correct mgmt api naming
* feat: new command to generate mgmt api sections
* feat: sort section items
* chore: tidy up
* fix: add generate sections to the default command
* feat: add gha to auto update mgmt api docs
* chore: tidy up
* fix: operationId logic to support self-hosting references
* chore: update latest mgmt api specs
* chore: update latest mgmt api specs