question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. ItĀ collects links to all the places you might be looking at while hunting down a tough bug.

And, if youā€™re still stuck at the end, weā€™re happy to hop on a call to see how we can help out.

Should we use a monorepo structure for addons?

See original GitHub issue

Iā€™m beginning to think it will be much easier to manage the addons if we just include them as part of the xterm repo (in <root>/addons/<addon>?) but still upload them separately to npm. That way we could test them all as part of our CI to ensure breakages donā€™t happen across versions, like what might have happened to ligatures recently. The main downsides I see are that issues will all remain in the 1 repo (maybe thatā€™s good?) and they wonā€™t be as good examples of what an external addon should be.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:9 (9 by maintainers)

github_iconTop GitHub Comments

1reaction
mofuxcommented, Jun 2, 2019

I see, thatā€™s fine with me šŸ‘ Letā€™s go with #2164 then - and thanks for all the effort you are putting into the whole restructuring / refactoring ā¤ļø

1reaction
Tyriarcommented, Jun 2, 2019

I ended up removing --modules-folder as it didnā€™t work the way I expect it to, when running yarn in the addon ../../node_modules would get cleared out and replaced with just ws and @types/ws, I was expected it to be additive but it makes sense now that I think about it. Instead of trying to duplicate the dependencies right now everything just uses the root node_modules and addon dependencies become devDependencies of the root package.json (just ws and @types/ws for attach testing).

Each addon only has a single npm script:

"prepublishOnly": "../../../node_modules/.bin/tsc -p src"

So npm publish will always do a build beforehand, another complication with sharing the modules or duplicating them in the addons is that the typescript versions could differ and cause confusion. They all share the same primary dependencies anyway so sharing makes sense (puppeteer, mocha, typescript, etc.).

Read more comments on GitHub >

github_iconTop Results From Across the Web

What is monorepo? (and should you use it?) - Semaphore CI
A monorepo is a version-controlled code repository that holds many projects. While these projects may be related, they are often logicallyĀ ...
Read more >
Monorepos and why to consider them for your team's iOS ...
Choosing an intuitive directory structure is an important first step in setting your team up for success using a monorepo. With a reasonableĀ ......
Read more >
Monorepo vs Multi-Repo: Pros and Cons of Code Repository ...
There are two main strategies for hosting and managing code through Git: monorepo vs multi-repo. Both approaches have their pros and cons.
Read more >
Why might a project/company use a monorepo?
While monorepos make sharing modules, updating dependencies, and working on FE/BE a lot easier, you trade that inconvenience for tooling aroundĀ ...
Read more >
The Case for Monorepos: A sane Workspace Setup (Part 2)
Dependending on what frameworks you are using and how your individual packages are structured, you might need further tsconfig.json adjustmentsĀ ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found