fix(readme.md): reorder installation steps in README.md#851
fix(readme.md): reorder installation steps in README.md#851Jah-yee wants to merge 1 commit intogoogle:mainfrom
Conversation
web_core must be built before markdown-it since markdown-it depends on @a2ui/web_core via file:../../web_core
|
Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). View this failed invocation of the CLA check for more information. For the most up to date status, view the checks section at the bottom of the pull request. |
There was a problem hiding this comment.
Code Review
This pull request correctly reorders the installation steps in the README.md file to address a dependency issue where web_core must be built before markdown-it. The change is logical and well-explained. I have added one suggestion to improve the robustness of the shell commands provided in the documentation.
| # Install and build the Web Core library (must be built first - markdown-it depends on it) | ||
| cd renderers/web_core | ||
| npm install | ||
| npm run build | ||
|
|
||
| # Install and build the Web Core library | ||
| cd ../../web_core | ||
| # Install and build the Markdown renderer | ||
| cd ../markdown/markdown-it | ||
| npm install | ||
| npm run build |
There was a problem hiding this comment.
For better robustness and user experience, consider running the build commands for each package within a subshell (...). This prevents the cd command from changing the user's current directory and makes each step runnable independently from the project root. Chaining commands with && also ensures that subsequent commands only run if the previous ones succeed.
For example:
# Install and build the Web Core library (must be built first - markdown-it depends on it)
(cd renderers/web_core && npm install && npm run build)
# Install and build the Markdown renderer
(cd renderers/markdown/markdown-it && npm install && npm run build)
Description
The markdown-it build requires dependencies in web_core like
@a2ui/web_core:file:../../web_core. Without building web_core first,npm run buildon the markdown-it project fails with missing dependency errors.This PR reorders the installation steps so that web_core is built before markdown-it.
Before
After