5999e18a Moved limit-service into the monorepo
Ghost took its limits from a package published out of TryGhost/SDK, so adding one
meant a pull request there, a release, and a version bump here before a site
could be limited. Nothing outside Ghost consumes it: across the org's
repositories the only others referencing it are forks of Ghost and the archived
standalone Admin, so there is nobody to publish for.
The source is copied exactly as it stands at af752ec in that repository, with no
renames, no reformatting and no change to what it does, so this can be checked by
diffing the two. Its own tests come with it. The only edits are what Ghost needs
to consume it: private at an internal version, repository metadata and publishing
configuration pointed here, and the three consumers resolving it as a workspace
package. It is left out of the repository formatter and documentation linter for
now so that comparison stays possible. The dependency rule that grouped its
version bumps into their own pull request goes with it, since there are no longer
any to group.
One thing did have to change around it. The package is CommonJS, which a browser
bundler only converts while pre-bundling, so consumed as workspace source rather
than from the registry it was served raw to Admin, the import failed, and the
limiter quietly reported every host limit as absent. It is forced through the
pre-bundler until the package itself is converted, which the next change does.
The tests pinning what a limit does to a site pass unchanged, which is the point
of doing this on its own.
ref https://linear.app/ghost/issue/BER-3797 040db927 Moved limit-service into the monorepo
Ghost took its limits from a package published out of TryGhost/SDK, so adding one
meant a pull request there, a release, and a version bump here before a site
could be limited. Nothing outside Ghost consumes it: across the org's
repositories the only others referencing it are forks of Ghost and the archived
standalone Admin, so there is nobody to publish for.
The source is copied exactly as it stands at af752ec in that repository, with no
renames, no reformatting and no change to what it does, so this can be checked by
diffing the two. Its own tests come with it. The only edits are what Ghost needs
to consume it: private at an internal version, repository metadata and publishing
configuration pointed here, and the three consumers resolving it as a workspace
package. It is left out of the repository formatter and documentation linter for
now so that comparison stays possible. The dependency rule that grouped its
version bumps into their own pull request goes with it, since there are no longer
any to group.
One thing did have to change around it. The package is CommonJS, which a browser
bundler only converts while pre-bundling, so consumed as workspace source rather
than from the registry it was served raw to Admin, the import failed, and the
limiter quietly reported every host limit as absent. It is forced through the
pre-bundler until the package itself is converted, which the next change does.
The tests pinning what a limit does to a site pass unchanged, which is the point
of doing this on its own.
ref https://linear.app/ghost/issue/BER-3797 fe30c8c7 Moved limit-service into the monorepo
Ghost took its limits from a package published out of TryGhost/SDK, so adding one
meant a pull request there, a release, and a version bump here before a site
could be limited. Nothing outside Ghost consumes it: across the org's
repositories the only others referencing it are forks of Ghost and the archived
standalone Admin, so there is nobody to publish for.
The source is copied exactly as it stands at af752ec in that repository, with no
renames, no reformatting and no change to what it does, so this can be checked by
diffing the two. Its own tests come with it. The only edits are what Ghost needs
to consume it: private at an internal version, repository metadata and publishing
configuration pointed here, and the three consumers resolving it as a workspace
package. It is left out of the repository formatter and documentation linter for
now so that comparison stays possible.
One thing did have to change around it. The package is CommonJS, which a browser
bundler only converts while pre-bundling, so consumed as workspace source rather
than from the registry it was served raw to Admin, the import failed, and the
limiter quietly reported every host limit as absent. It is forced through the
pre-bundler until the package itself is converted, which the next change does.
The tests pinning what a limit does to a site pass unchanged, which is the point
of doing this on its own.
ref https://linear.app/ghost/issue/BER-3797 38c6d556 Moved limit-service into the monorepo
Ghost took its limits from a package published out of TryGhost/SDK, so adding one
meant a pull request there, a release, and a version bump here before a site
could be limited. Nothing outside Ghost consumes it: across the org's
repositories the only others referencing it are forks of Ghost and the archived
standalone Admin, so there is nobody to publish for.
The source is copied exactly as it stands at af752ec in that repository, with no
renames, no reformatting and no change to what it does, so this can be checked by
diffing the two. Its own tests come with it. The only edits are what Ghost needs
to consume it: private at an internal version, repository metadata and publishing
configuration pointed here, and the three consumers resolving it as a workspace
package. It is left out of the repository formatter and documentation linter for
now so that comparison stays possible.
One thing did have to change around it. The package is CommonJS, which a browser
bundler only converts while pre-bundling, so consumed as workspace source rather
than from the registry it was served raw to Admin, the import failed, and the
limiter quietly reported every host limit as absent. It is forced through the
pre-bundler until the package itself is converted, which the next change does.
The tests pinning what a limit does to a site pass unchanged, which is the point
of doing this on its own.
ref https://linear.app/ghost/issue/BER-3797