My team is working on a project using a setup with "force cli" [https://force-cli.heroku.com/] & "sublime-lightning" [https://github.com/dcarroll/sublime-lightning]. This setup allow us to work as a team with our own individual org and sharing and version controlling code via SVN.

We got our fonts, generated with icomoon [https://icomoon.io], put the files (EOT, SVG, TTF, WOFF & WOFF2) on a folder called "myfonts"and ziped the folder. As a next step we upload the zip file to our static resources and we can then use it without a problem.

Using "force-cli" I can then download my "Static Resources" to my local environment and commit it to SVN allowing the other developer to grab it and use it. The fonts are converted to a binary file and this method worked just fine.

The problem is when we try to update the font-files. Everything work to the point where I upload the zip file to my org, but once I fetch the font file to my local environment and the other developer or even myself try to upload the new file, somehow it doesn't work and instead of the new file it shows the older one.

I've tried to delete the file from my Static Resources and all other possibilities the crossed my mind but so far, no progress. The only way that we found to have this working, is manually uploading the zip file to each org.

Any ideas on that? :)

As per Peter comment request, on my wrapper component I have:

<ltng:require styles="/resource/coreCSS, /resource/qunitCSS" scripts="/resource/jquery, /resource/highstock, /resource/qunitJS" afterScriptsLoaded="{!c.myAction}" />

My coreCSS is generated using SASS but it basically looks like this:

@font-face {
    font-family: 'icomoon';
    src:url('/resource/fonts/icomoon-font/icomoon.eot?#iefix') format('embedded-opentype'),
        url('/resource/fonts/icomoon-font/icomoon.woff') format('woff'),
        url('/resource/fonts/icomoon-font/icomoon.woff2') format('woff2'),
        url('/resource/fonts/icomoon-font/icomoon.ttf') format('truetype'),
        url('/resource/fonts/icomoon-font/icomoon.svg#icomoon') format('svg');
        font-weight: normal;
        font-style: normal;

I like to point out that the icons from the very first upload still works just fine. The problem is just with the icons that have been added to font and uploaded after the first upload.

  • 2
    Do you think its caching issue ? Did you try to reload instead of refresh or try to hit static resource URL generated by browser and refresh that content ? Commented Aug 20, 2015 at 16:51
  • That was the first thing that came in mind. Definitely not a browser caching issue. When I upload the zip file, on salesforce static resources it shows a 40kb file but when I fetch it and save it again it changes the file size to 38kb. It could be a caching issue on SF side. Commented Aug 20, 2015 at 17:11
  • Please post the syntax of how you reference the static resource.
    – pchittum
    Commented Aug 21, 2015 at 7:07
  • @Peter - Just did. I added the info to my question but as I'm pointing out the icons works just fine until the point when I update the icomoon font directly to my static resources. The problem begins when I fetch the files using "Force CLI" and upload the those files to my org again or when my coworkers upload the file that I fetched from my org to their orgs. Commented Aug 21, 2015 at 17:43
  • I'd just like to add that I too am seeing this issue. I uploaded a simple css file, and referenced it with ltng:require. I updated the css file, but the css changes aren't getting reflected. I found that the difference is the ltng component is looking for na24.lightning.force.com/resource/<name>, and the css file is in an old state, where as na24.force.com/resource/<name> has the correct up-to-date changes. Commented Sep 1, 2015 at 22:23


You must log in to answer this question.

Browse other questions tagged .