Skip to content

Dependency on PrefixFree #21

Munter opened this Issue Oct 21, 2011 · 11 comments

5 participants

Munter commented Oct 21, 2011
  • commit cf3799c (HEAD, refs/bisect/bad) | Author: Lea Verou | Date: Thu Oct 20 02:49:56 2011 | | -prefix-free integration, dropped older css-prefix.js

This commit added a regression since you are referencing prefixfree outside of the scope of the project, which assumes that users of CSSS will have prefixfree installed at the exact same location as you have locally.

Prefixfree should be should be added as a submodule to fix this.

Munter commented Oct 21, 2011

I forgot to add that the regression I spotted was the missing transitions when changing items and slides


Hi Munter,

Yes, I was thinking about this myself. I read about how to add submodules, but I'm still kinda scared to try it out.
Do you have any example of a repo that uses submodules, so that I can check out how it works when cloning, pulling etc?


Munter commented Oct 22, 2011

I actually pull in CSSS as a submodule in One-color.js at /slides/3rdparty/

We use it at lot at work for external dependencies and for our own libs that have been open sourced and moved to github.

The basic concept resembles that os a symlink, but hardcoded to a specific commit on the submodule. So when using submodules you need to manually update your reference to a new version when you update prefixfree. This adds an extra working step, but also helps you remember to test that there are no regressions.

Workflow for committing a submodule version update:

cd submodule/path/
git pull (or checkout specific version)
cd root/of/CSSS
git commit .gitmodules

You usually need to remember the users of the library that they need to pull in submodules as well:

git submodule update --init

If you ever spot a regression in CSSS caused by something in prefixfree you can fix the bug right there inside your submodule checkout, which I find useful for direct testing without making roundtrips through github to test.


Thanks for the explanation!

So it has to be a folder inside each repo, it can't be outside like now, right?
Is there a way to make it work with the current reference?

Munter commented Oct 22, 2011

The repo can't track anything outside itself, so no-go on that.
I don't see a way it can work in a way where you can refer to prefixfree outside the CSSS folder and still expect it to work when people clone jsut CSSS.

A simple solution could of course be to check in a copy of prefixfree.min.js inside CSSS and update that when needed. That of course gives you less possibilities to debug.

@Munter Munter closed this Oct 22, 2011
@Munter Munter reopened this Oct 22, 2011
Munter commented Oct 22, 2011

That close button certainly is 'close' to the comment button :)


The problem is that I also upload everything to my website, and need it to work both locally, and remotely, and on gh-pages. So, that would be a problem. Now I neatly have a different folder for everything, and it even works on gh-pages, when the other repo has a page too.

I'll think about what I can do. Although I don't think it's that hard to clone the other repo as well. But it could become a hassle once I introduce more dependencies. :(


Ha, I know why you clicked the close button. If you post a comment with 6 lines and then click "Comment" and keep your mouse pointer in the same position, after it's posted, your mouse is exactly over "Close issue"!


How about putting something in the readme telling people to put the PrefixFree folder below CSSS to get things working ? Not an ideal solution but may save some people a little time in the meanwhile.


I really like shavenyaknz idea. Otherwise it might be great to simply add the latest version of prefix-free to CSSS to make morking from the beginning.


I request #22 to make prefixfree as submodule and solve it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.