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

rev keywords #199

Open
littledu opened this issue Oct 12, 2018 · 1 comment
Open

rev keywords #199

littledu opened this issue Oct 12, 2018 · 1 comment

Comments

@littledu
Copy link

I have an index.js file that exists in below code:

for(var i=0;i<allDots.length;i++){
        allDots[i].addEventListener("click",function(){
            var index= [].indexOf.call(allDots, this);
            bannerTl.seek("index"+(index+1));
        })
    }

After compilation, the code becomes:

for(var i=0;i<allDots.length;i++){
        allDots[i].addEventListener("click",function(){
            var index= [].indexOf.call(allDots, this);
            bannerTl.seek("index.f22f6e73"+(index+1));
        })
    }

bannerTl.seek("index"+(index+1)); -> bannerTl.seek("index.f22f6e73"+(index+1));

so sad!, how can I solve it?

@pioug
Copy link
Collaborator

pioug commented Nov 3, 2018

@littledu Thanks for reporting the bug. Unfortunately there is a whole branch for handling "extensionless" references to JS files 🙈 https://github.com/smysnk/gulp-rev-all/blob/master/revisioner.js#L62. I went a bit in the commit history and I think the purpose is solving references when using CommonJS.
Maybe you can play with some settings https://github.com/smysnk/gulp-rev-all#dontupdatereference to ignore index.js?

        { dontUpdateReference: ["index.js"] }

But it's gonna ignore actual references to index.js 🙈 I don't know enough about this project to propose a patch.

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

No branches or pull requests

2 participants