I've got a nice, fairly popular JavaScript library that is following Semantic Versioning.

The current library has a few dependency libraries, which are available either as separate downloads or as part of a single bundled download. I see a need to head down this path further. I want to extract additional, smaller libraries out of the one larger library. Each of these extracted libraries would be available as separate files, or inside of the one bundled build, again.

If I go down this path of extracting the libraries, and providing a bundled version of the final code, does this require a full version change in semantic versioning? Would I have to bump from 1.x to 2.x?

My first thought it no: I will not change any public API, so I don't have to change the major version number. But then I wonder... well, I am restructuring a lot of things, even though the final API for the bundled version would be the same.

Is there a clear answer from semver on something like this? Do I need to bump first, second or third dot? Or something else?

  • What exactly are you changing? Are you changing your project's file structure, or only offering a different type of download? Aug 14 '13 at 14:12
  • both of those... the file structure, and the option of download individual parts instead of all-or-nothing Aug 14 '13 at 14:16

You should increment the patch (third) number.

While you are not fixing a bug, you are refactoring, that is modifying the structure of the problem without changing its behavior. You are also not changing the public API.

Relevant quotes from Semantic Versioning below

What should I do if I update my own dependencies without changing the public API?

That would be considered compatible since it does not affect the public API. Software that explicitly depends on the same dependencies as your package should have their own dependency specifications and the author will notice any conflicts. Determining whether the change is a patch level or minor level modification depends on whether you updated your dependencies in order to fix a bug or introduce new functionality. I would usually expect additional code for the latter instance, in which case it's obviously a minor level increment.


Patch version Z (x.y.Z | x > 0) MUST be incremented if only backwards compatible bug fixes are introduced. A bug fix is defined as an internal change that fixes incorrect behavior.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.