Yes, you can do that. You can install two versions of same npm
modules. First of all, delete the existing version and install using this command and you can provide the version number to install it. This is the command:
npm i <package_name_alias>@npm:<package_name>
In your case, it should become this(for latest version):
npm i latest-ckEditor5@npm:ckEditor5
And for any other version lower than the latest use this:
npm i latest-ckEditor5@npm:ckEditor5@versionNumber
In your package, it will look something like this:
"dependencies": {
"latest-ckEditor5": "^latestPackage",
"oldest-ckEditor5": "Olderverion"
}
You can use them like this:
import { ckEditor5 } from 'latest-ckEditor5'; // check the exported member name
import { ckEditor5 } from 'oldest-ckEditor5';