有一个简单的过程来放置按钮复制gitbook的代码。在下单时,怎样做才能做到呢?
# install npm
curl -sL https://deb.nodesource.com/setup_10.x | sudo -E bash -
sudo apt-get install -y nodejs
# install gitbook builder
sudo npm install -g gitbook
sudo npm install -g gitbook-cli
# git clone gitbook "example" repository
git clone ...
cd gitbook/
npm init
# Install plugin to add clipboard button for code
# https://www.npmjs.com/package/gitbook-plugin-copy-code-button
npm install gitbook-plugin-copy-code-button创建index.md
在本例中,在Rstudio中,新的Template>github中的
并制作book.json
{
"structure": {
"readme": "index.md"
},
"plugins": ["copy-code-button"]
}最后,gitbook build .

发布于 2019-09-20 15:36:45
We just added the Copy button在开发版的下订下。你可以通过
remotes::install_github('rstudio/bookdown')要回答您最初的问题:目前无法在bookdown中使用gitbook插件。
https://stackoverflow.com/questions/58017029
复制相似问题