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 CSS and JS scripts to template for create true overrides #27

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

leoalv
Copy link

@leoalv leoalv commented May 23, 2021

Currently the pages must be fast, and better if it makes few requests to the server.

Loading embedded videos from youtube or vimeo on a website increases requests (approximately 11); so trying to reduce that I created an everride of the module, to eliminate the previews of the video, which was obtained as expected. But the module still continued to load the featherlight.min.js and featherlight.min.css files, when they were no longer needed, and the loading of those files could not be nulled because an override of the mod_spsimpleportfolio.php file cannot be created. Do the same if you want to switch to another preview script.

These changes that I am proposing solve that problem by giving better control over the files from the override.

Removed scripts JS and CSS for add in tmpl/default.php
Added JS ans CSS files from mod_spsimpleportfolio.php so user can remove or change scripts from template override.
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

Successfully merging this pull request may close these issues.

1 participant