Skip to content
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

Move text content to separate file #132

Open
fchrapek opened this issue Sep 27, 2023 · 3 comments
Open

Move text content to separate file #132

fchrapek opened this issue Sep 27, 2023 · 3 comments

Comments

@fchrapek
Copy link

Hi @satnaing, great work - I love the template!

I have a couple ideas that might be worth considering.

One of them is to move all the static text content (headings, descriptions, button names etc.) to one place for a bit easier management. In my case, I moved it to a separate JS object in a new file. Then it's just a matter of importing it wherever you might need it.

What do you think?

@satnaing
Copy link
Owner

satnaing commented Oct 3, 2023

Yep.
This might be beneficial for AstroPaper users when they want to upgrade the template. I'm also considering integrating a CLI for AstroPaper in the future, so it could be worthwhile.

However, on the other hand, it might be a bit confusing for some users when they want to customize/extend the template.

Can you also provide me a repo or link as an example for your approach?

@fchrapek
Copy link
Author

fchrapek commented Oct 3, 2023

I'm relatively new to the modern JS framework scene, so I'm not saying this solution is anywhere close to the best one, but here is what I did:

https://github.com/fchrapek/filipchrapek.pl/blob/main/src/content/content.js

@SSmale
Copy link
Contributor

SSmale commented Dec 30, 2023

It would also be good to Get a section on all the things that need to be edited to make this your own (or move the content to a central location) .

  • src/pages/about.md
  • src/pages/index.astro

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants