0
Welcome Guest! Login
0 items Join Now

Use CDN instead of hard code in Gantry?

    • k3vmo's Avatar
    • k3vmo
    • Sr. Rocketeer
    • Posts: 145
    • Thanks: 2

    Use CDN instead of hard code in Gantry?

    Posted 9 years 6 months ago
    • I've been using sites like Pingdom to test out the various demos.

      Is it possible to add a reference or change to have things like fontawesome, mootools and jquery point to the most current version on a CDN (a lot of other programmers do this to reduce requests to the server) *rather* than it be sent from gantry?

      I'd prefer not to manually modify gantry each time there is an update.
    • - - It is a rough road that leads to greatness.
    • MrT's Avatar
    • MrT
    • Preeminent Rocketeer
    • Posts: 101084
    • Thanks: 13484
    • Web Designer/Developer

    Re: Use CDN instead of hard code in Gantry?

    Posted 9 years 6 months ago
    • You should update Gantry manually because you should test any update first in a clone of your site (a test area). Sometimes a Gantry update also needs a template updates and vice-versa too. When we load JS libraries we do already use cdnjs - but you will note that they specify a specific version for exactly the same reason.

      Regards, Mark.
    • Please search forums before posting. Please make sure your post includes the version of the CMS you are using and a link to the problem. Annotations on screenshots can also be helpful to explain problems/goals. Please use the "secure" tab for confidential information.
    • k3vmo's Avatar
    • k3vmo
    • Sr. Rocketeer
    • Posts: 145
    • Thanks: 2

    Re: Use CDN instead of hard code in Gantry?

    Posted 9 years 6 months ago
    • Just to confirm I understand - I should leave 'as-is' because *potentially* a jquery update (if I use from a CDN) could cause conflicts or things to stop working?
    • - - It is a rough road that leads to greatness.
    • MrT's Avatar
    • MrT
    • Preeminent Rocketeer
    • Posts: 101084
    • Thanks: 13484
    • Web Designer/Developer

    Re: Use CDN instead of hard code in Gantry?

    Posted 9 years 6 months ago
    • Of course - any update of anything can cause issues - that is why you should always test every update before applying it for real on your site. Where we already do use libraries from cdnjs we specify the version number required - in other words, that version would never be changed on Cdnjs and is therefore safe to use, when something get's updated it's version number would change, we would only specify the new version in our code (from cdnjs) if it had gone through our testing regime first.

      Regards, Mark.
    • Please search forums before posting. Please make sure your post includes the version of the CMS you are using and a link to the problem. Annotations on screenshots can also be helpful to explain problems/goals. Please use the "secure" tab for confidential information.

Time to create page: 0.062 seconds