From df1d3085e7214786948e0f9edcfaaf05327ef566 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rapha=C3=ABl=20Benitte?= Date: Thu, 7 Dec 2017 14:13:10 +0900 Subject: [PATCH] feat(dev): add commands to list/rm currently linked packages for website --- Makefile | 18 ++++++++++++++++++ README.md | 1 + website/src/components/charts/bar/Bar.js | 4 ---- .../src/components/charts/heatmap/HeatMap.js | 4 ---- 4 files changed, 19 insertions(+), 8 deletions(-) diff --git a/Makefile b/Makefile index ca0c9774bd..fdac2b8fd9 100644 --- a/Makefile +++ b/Makefile @@ -150,6 +150,24 @@ website-deploy: ##@website build & deploy website @echo "${YELLOW}Deploying website${RESET}" @./node_modules/.bin/gh-pages -d website/build -r git@github.com:plouc/nivo.git -b gh-pages +website-audit: ##@website audit website build + @cd website && yarn analyze + +website-links-ls: ##@website list linked packages + @echo "${YELLOW}Which packages are currently being linked to ${WHITE}website${YELLOW}?${RESET}" + @cd website; \ + find node_modules node_modules/\@* -depth 1 -type l -print | awk -F/ '{print $$(NF)}' | while read MODULE; do \ + echo "> linked package: ${WHITE}$${MODULE}${RESET}"; \ + done + +website-links-rm: ##@website unlink all linked packages + @echo "${YELLOW}Unlinking all packages for ${WHITE}website${RESET}" + @cd website; \ + find node_modules node_modules/\@* -depth 1 -type l -print | awk -F/ '{print $$(NF)}' | while read MODULE; do \ + yarn unlink "@nivo/$${MODULE}"; \ + done + @cd website && yarn install + ######################################################################################################################## # # STORYBOOK diff --git a/README.md b/README.md index 638e512f5e..69fa01e326 100644 --- a/README.md +++ b/README.md @@ -112,6 +112,7 @@ Join the [nivo discord community](https://discord.gg/n7Ft74f). ## Guides * [colors](http://nivo.rocks/#/guides/colors) +* [legends](http://nivo.rocks/#/guides/legends) * [gradients](http://nivo.rocks/#/guides/gradients) * [patterns](http://nivo.rocks/#/guides/patterns) diff --git a/website/src/components/charts/bar/Bar.js b/website/src/components/charts/bar/Bar.js index 1f2cc2b60a..4b41325b5d 100644 --- a/website/src/components/charts/bar/Bar.js +++ b/website/src/components/charts/bar/Bar.js @@ -218,10 +218,6 @@ export default class Bar extends Component { the storybook .

-

- See the dedicated guide on how to setup - legends for this component. -

) diff --git a/website/src/components/charts/heatmap/HeatMap.js b/website/src/components/charts/heatmap/HeatMap.js index 87517ce827..2e41203557 100644 --- a/website/src/components/charts/heatmap/HeatMap.js +++ b/website/src/components/charts/heatmap/HeatMap.js @@ -190,10 +190,6 @@ export default class HeatMap extends Component { the storybook .

-

- See the dedicated guide on how to setup - legends for this component. -

)