Learn English vocabulary for package dependency resolution: dependency tree, peer dependencies, hoisting, phantom dependencies, workspaces, and resolution algorithms.
0 / 10 completed
1 / 10
A 'dependency tree' in package management represents:
When you install lodash, lodash may depend on package A, which depends on package B. The dependency tree maps all these nested relationships. Deep trees with conflicting version requirements are the core challenge of dependency resolution.
2 / 10
'Peer dependencies' in a package's package.json signal that:
Peer deps say 'I expect the host project to provide this package.' React plugin packages use peer deps for react — they don't bundle React, they expect the project using them to have React installed. This avoids duplicate React instances.
3 / 10
'Hoisting' in npm's node_modules means:
npm hoists packages to reduce duplication — if package A and package B both need lodash@4.17.21, npm places one copy at the root node_modules level rather than two nested copies. Hoisting is why you can sometimes accidentally use packages you haven't explicitly installed.
4 / 10
A 'phantom dependency' problem occurs when:
If package A hoists lodash into your root node_modules, you can import lodash in your code even without listing it. But if A ever stops depending on lodash, it disappears from your node_modules and your code breaks — this is a phantom dependency bug.
5 / 10
'Workspaces' in npm, Yarn, and pnpm allow developers to:
Workspaces link packages within a monorepo locally — package B can import from package A without publishing to the registry. The package manager hoists shared dependencies to the root and symlinks local packages, enabling monorepo development.
6 / 10
Sarah: 'I'm getting a conflict in my `package.json`! It says 'version mismatch' for the lodash dependency. What does that typically mean?',
'Version mismatch' in dependency resolution indicates that different packages within your project or its transitive dependencies require conflicting versions of a shared dependency, like lodash. This often happens when a package updates its own requirements and another package hasn't yet been updated to accommodate the change, leading to a broken build.
7 / 10
Mark (in a Slack channel): 'I've added a new react-router-dom dependency to my component. The CI is failing because it claims I need to explicitly declare a peer dependency on react.' What is the purpose of this peer dependency declaration
Peer dependencies are designed to solve compatibility issues between packages that rely on each other but might have different primary dependencies themselves. In this case, react-router-dom typically depends on a compatible version of react to function correctly; the peer dependency declaration enforces this link.
8 / 10
David (in a PR description): 'I've updated our project to use workspaces. This allows us to share code between our frontend and backend repositories without duplicating dependencies.' What is the primary benefit of using workspaces in package management
The core benefit of workspaces is efficient code reuse and reduced redundancy. By sharing a common set of dependencies between related projects (like frontend and backend), you avoid installing the same packages multiple times, saving disk space, reducing build times, and simplifying dependency management.
9 / 10
Emily: 'I'm seeing a 'phantom dependency' error in my build. It's complaining about a module that doesn't seem to be directly included in any of our code, but it's showing up in the node_modules folder.' What is likely causing this
A 'phantom dependency' typically arises when a transitive dependency (a dependency of one of your direct dependencies) is unintentionally included in the project's node_modules folder. This can happen due to incorrect configuration or inconsistencies in dependency resolution processes – it doesn't mean the package itself isn't needed, just that it's present unexpectedly.
10 / 10
John: 'We're adopting Yarn workspaces to improve our development workflow. We can now manage dependencies for multiple projects within a single repository.' What is the primary advantage of using a tool like Yarn with workspaces
Yarn is known for its speed and reliability in dependency resolution, particularly within a workspace environment. Its algorithm typically performs better than npm's default resolver, leading to quicker builds and more predictable outcomes when managing multiple projects with shared dependencies. This efficiency reduces build times and improves developer productivity.
What will I practise in "Dependency Resolution Vocabulary"?
This module focuses on Package Management — real workplace phrasing you'll use on the job. It contains 10 scenario-based multiple-choice questions with instant feedback.
Is this exercise free to use?
Yes. Every exercise on CoderSlingo, including this one, is free to use with no account or sign-up required.
How many questions does this exercise have?
This module includes 10 questions. Each one gives an immediate right/wrong result plus a full explanation of the correct phrasing.
What happens if I answer a question incorrectly?
You'll see the correct answer highlighted straight away, along with a plain-English explanation of why it's right and why the other options don't fit — mistakes are part of the learning here.
Can I retry the exercise if I want a better score?
Yes — use the 'Try again' button on the results screen to reset your score and go through the questions again. There's no limit on attempts.
Who is this Package Management exercise for?
It's aimed at IT professionals with working English who want to sound more natural and precise around package management — useful whether you're preparing for real conversations at work or just building confidence with the vocabulary.
Do I need an account to track my progress?
No account is needed. Your progress through the exercise is tracked locally in your browser for the current session, and you can replay the module at any time.
How is this different from reading a blog article?
This exercise is an interactive drill that tests and reinforces specific phrasing through multiple-choice questions with instant feedback, while blog articles explain concepts and vocabulary in prose. The two work well together.
Where can I find more Package Management exercises?
See the Package Management hub for more modules like this one, or browse the full Exercises page for other IT-English topics.
Can I complete this exercise on my phone?
Yes — every exercise on CoderSlingo is fully responsive and works on phones and tablets, so you can practise anywhere.