site icon indicating copy to clipboard operation
site copied to clipboard

Variables documentation does not mention types of Warehouse objects

Open ghost opened this issue 7 years ago • 5 comments

This one had me stumped for very very long! Neither the docs or the examples made this clear at all, I didn't find it until looking in the troubleshooting section. It could reasonably be as simple as the paranthesis notes regarding the datetime objects.

ghost avatar Jun 11 '17 21:06 ghost

Could you please create a PR for this documentation change, as I'm not sure exactly the issue is?

NoahDragon avatar Jun 14 '17 13:06 NoahDragon

I'm really busy until thursday next week, so I'm afraid I can't for now (although I'll be sure to once I resume development, if still needed).

Check https://hexo.io/docs/variables.html#Page-Variables

Look the page.updated and page.date entries, which note that they're Moment.js objects. The same should be done with Warehouse objects. In fact it might be best to add a type field for all variables.

ghost avatar Jun 15 '17 21:06 ghost

Thanks for the info. I will take a look.

NoahDragon avatar Jun 16 '17 13:06 NoahDragon

Addressed partially in #510. It's on the main branch now, so it's visible on the live page. Some placeholders for what I didn't figure out are present in the form of ???, most of these being some kind of Warehouse objects, or arrays of them, I believe. Warehouse objects should point to the Warehouse documentation, much like Moment.js objects do.

Additionally I'm not 100% sure if everything I wrote is correct, so feel free to double check!

ghost avatar Jul 07 '17 19:07 ghost

@Krakob Thank you. I think I will definitely look into it when I have time, I promise. 😄

NoahDragon avatar Jul 11 '17 13:07 NoahDragon