-
Notifications
You must be signed in to change notification settings - Fork 138
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
note loaders #1776
note loaders #1776
Conversation
…ted by source = 'telemetry.md.js'.
I'm not sure I'm following what this is doing exactly. I used this to build the Framework docs, and the generated I expected this manifest would only list items when they were a part of the |
fix manifest for non-exported files and modules (but commented out)
Thanks for the review. I have now:
Fixing code to comment it out is a bit of a contradiction. It is because, even if it's out of scope for now, I think there is value potentially in knowing which (non-exported) files and modules depend on which source files. So maybe it would be right to uncomment these two calls, even if we don't yet have a reporter script to make use of them. (Or at least we know that we can reinstate them when we want.) For instance, for an internal (non exported) parameterized module, it's nice to know that {
"params": {"type": "exported"},
"path": "/_import/module-exported.281d2524.js",
"source": "/module-[type].js"
} |
I agree that information would be interesting. I think that I'd want to be able to distinguish the unexported items from the exported ones though. Maybe with a boolean flag? |
|
tested live… 🎉 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Apologies, I didn't realize this was waiting on me.
src/build.ts
Outdated
files: [] | ||
}; | ||
const addToManifest = (type: string, file: string, {title, path}: {title?: string | null; path?: string}) => { | ||
const source = path == null || path === file.slice(1) ? null : join("/", path); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is path == null || path === file.slice(1)
testing?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
path === file.slice(1)
is for files that point to themselves (e.g. path=chart.js
file=/chart.js
)
the path
is null
for pages that have no source
this is only used in the tests for parseMarkdown
… I can find a better way to express this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A bit better now; I'm still a bit unhappy with the naming (too many things we call "path")
config:{root}
to the build manifest