Comments (5)
Yes, you have to create a page in javascript or typescript exporting a generator. You have an example with pagination here: https://lumeland.github.io/creating-pages/pagination/
Basically, every value returned by a generator will be converted to a page. The 11ty example would be something like this:
// possum-pages.tmpl.js
export default function *({possums}) {
for (const possum of possums) {
yield {
permalink: `possums/${possum.name}/`,
content: `${possum.name} is ${possum.age} years old`
}
}
}
from lume.
Excellent! Now I see that in the docs 🤦
Thanks for clarifying!
from lume.
@oscarotero Maybe convert this issue to a discussion in section "Q&A"?
from lume.
@shadowtime2000 That's a good idea. Can we move/convert this issue to a discussion? Or we need to create a new discusion from scratch?
from lume.
@oscarotero I think you will be able to convert this issue to a discussion, just click "Convert to discussion" where it says pin issue and transfer issue.
from lume.
Related Issues (20)
- Lume serve: expected to respect ServerOptions for location HOT 2
- @std/log not found in registry-staging.deno.com HOT 2
- lume().copy() is a no-op when lume({src: "docs" }) is set HOT 4
- search.pages() return results is zero HOT 2
- How to use "lume-code" and "Tip caution..." in "tailwind typography" HOT 2
- InvalidStateError: readyState not OPEN HOT 1
- Lume fails to import nonexisting cms module HOT 1
- Did `basename` just break `esbuild` plugin? HOT 1
- Merged key in the layouts
- inline plugin types for JSX
- webp asset files corrupted on build HOT 3
- How to include/inline external CSS (npm | cdn)
- Improve performance of some plugins with an internal cache
- search not finding generated pages (doesn't seem to be a renderOrder issue?) HOT 2
- Option to allow case sensitive filenames
- lume -s, Fail to copy file to where the path once was a directory HOT 2
- Images are no longer copied to dest. HOT 7
- buildOrder: make page render after all plugins are run HOT 6
- Transform Images plugin: "VipsOperation: class "jxlsave_buffer" not found" HOT 5
- HMR doesn't detect new _data.yml when remote file is specified HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from lume.