content
Currently, content files are loaded eagerly into the main JS bundle. The initial JS bundle size increases as you add more markdown content files. These files should be lazy-loaded to decrease the initial JavaScript bundle size.
Currently, the injectContentFiles()
produces a static list of content + frontmatter attributes. Need to figure out a way to produce the frontmatter attributes for this list and still lazy load the content.
https://github.com/analogjs/analog/blob/main/packages/content/src/lib/get-raw-files.ts#L1
Changing how these files are loaded will most likely be a breaking change to the types.
Workaround is to put the markdown content files as routes instead of in the /src/content
folder. With #233 the routes will be lazy loaded but some flexibility in display is lost
No response
Owner Name | analogjs |
Repo Name | analog |
Full Name | analogjs/analog |
Language | TypeScript |
Created Date | 2022-07-06 |
Updated Date | 2023-03-28 |
Star Count | 885 |
Watcher Count | 18 |
Fork Count | 67 |
Issue Count | 33 |
Issue Title | Created Date | Updated Date |
---|