Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Dependency on PrefixFree #21

Open
Munter opened this Issue · 11 comments

5 participants

@Munter
  • commit cf3799c (HEAD, refs/bisect/bad) | Author: Lea Verou me@leaverou.me | 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

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

@LeaVerou
Owner

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?

Thanks!

@Munter

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:

cd CSSS
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.

@LeaVerou
Owner

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

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
@Munter Munter reopened this
@Munter

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

@LeaVerou
Owner

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. :(

@LeaVerou
Owner

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"!

@adamfr33man

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.

@ichderfisch

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.

@jorgecasar

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.