How should I ... do ... robots.txt? Sitemap? #1996
Unanswered
kylehodgson
asked this question in
Q&A
Replies: 1 comment
-
One way to do this is to use the dynamicPaths option to add references to files that must be built at a given URL. For example, see https://github.com/Fil/pangea/blob/c7b2ee2fec2aead7b2741e7256556c16b4c04ebc/observablehq.config.ts#L16C17-L16C29 See #1199 for a related discussion. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I spent some time on a quick node script that pulls in
observable.config.js
paths
entries and mydynamicPaths
generator function fromand hands them to npm's
sitemap` library. Now I have a nice little sitemap.xml, and I'd like to reference it in my robots.txt. Which is easy! Except, how do I deploy either of these?I saw documentation somewhere about adding "external" files not managed by observable, and I did add this to
head
inobservable.config.js
:npm run build
doesn't copy robots.txt to the dist folder. I can do this as part of the CI pipeline of course - but I wanted to see if I was just missing something?Beta Was this translation helpful? Give feedback.
All reactions