In my weeknotes: Designing a write API for #datasette
https://simonwillison.net/2022/Nov/9/designing-a-write-api-for-datasette/
In my weeknotes: Designing a write API for #datasette
https://simonwillison.net/2022/Nov/9/designing-a-write-api-for-datasette/
@keithbloom that's a convention I use elsewhere in Datasette. If you have a database called "fixtures.db" and on called "tils.db" then the URLs to them will be /tils and /docs - e.g. https://til.simonwillison.net/tils - so I reserve "-" to mean "stuff that isn't a database, such as https://til.simonwillison.net/-/plugins
I'm using the same trick here - so /docs/mytable is the mytable table but /docs/-/create is the create-table API, avoiding clashing with a table called "create"
@simon ah, that makes sense and it's a nice pattern to avoid name collisions.
It caught my eye because the only other time I have seen this is in npm package URLs and I also wonder why it's there.