well - I am writing this topic, because I often see people modifying the files of Pagekit's core or files of third-party packages (themes or extensions).
Don't do that!
I know - it's an easy way to add or modify the behavior of Pagekit or a third-party-package, but it's bad style. If there's an update of the package you modified, all your changes will be overwritten immediately.
Of course you could say: "Ooooh, I will just not update the package. As long as it's working for me, I don't need updates."
Of course you could. This could work out for you - but what do you do once there's a security-related update? Or an update, that is required to support recent Pagekit releases? Sometimes, you need to update.
Instead of modifying the core-files, you could do the following:
- Add JS/CSS to Pagekit using on-board-possibilities (Admin-Dashboard > Sites > Settings > Code)
- Add JS/CSS to Pagekit using spqr/assets-extension
- Fork the theme or extension if you need to add something that is not JS/CSS-related
- Create view-overrides