{"_id":"gitbook-plugin-exercises","_rev":"40-7b44ad83b5bca6d05f14042b3fe6b29a","name":"gitbook-plugin-exercises","dist-tags":{"next":"2.0.0-alpha.2","alpha":"2.0.0-alpha.3","latest":"3.0.0"},"versions":{"0.0.0":{"name":"gitbook-plugin-exercises","version":"0.0.0","license":"Apache 2","_id":"gitbook-plugin-exercises@0.0.0","maintainers":[{"name":"samypesse","email":"samypesse@gmail.com"}],"homepage":"https://github.com/GitbookIO/plugin-exercises","bugs":{"url":"https://github.com/GitbookIO/plugin-exercises/issues"},"dist":{"shasum":"05f2b0d4204b92faa736d05b9d05fc0258648a84","tarball":"https://registry.npmjs.org/gitbook-plugin-exercises/-/gitbook-plugin-exercises-0.0.0.tgz","integrity":"sha512-vciuKpRN3ysn87luiqM+ab3WsNm2zpuM3OezTSpmMgKEH4K/mWCmEikVPiePJsbP4NbRyNF76zKY/UOLKf2lMA==","signatures":[{"sig":"MEUCIQDg8lDFKk7p2+pRjceO5k39kU2TWpAiZMJPDmIXfiILXQIgDB5sGlIXGwndmAXshjisrGV54BH6o24QQJ1LFucFi6M=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"index.js","_from":".","engines":{"gitbook":">=1.0.0"},"_npmUser":{"name":"samypesse","email":"samypesse@gmail.com"},"repository":{"url":"https://github.com/GitbookIO/plugin-exercises.git","type":"git"},"_npmVersion":"1.4.3","description":"Interactive exercices in a gitbook","directories":{}},"1.0.0":{"name":"gitbook-plugin-exercises","version":"1.0.0","license":"Apache 2","_id":"gitbook-plugin-exercises@1.0.0","maintainers":[{"name":"samypesse","email":"samypesse@gmail.com"}],"homepage":"https://github.com/GitbookIO/plugin-exercises","bugs":{"url":"https://github.com/GitbookIO/plugin-exercises/issues"},"dist":{"shasum":"3a88566b8235a75d6d7c0055bcb71aa6b27bb13e","tarball":"https://registry.npmjs.org/gitbook-plugin-exercises/-/gitbook-plugin-exercises-1.0.0.tgz","integrity":"sha512-smCjvZyJjQm0k8BWEY27+Ll1TmhmHskbAvmcXgZ96nBN1DbGaJiBapEZ8Q7Ax6IkJ+NG4Zg1g3cEfjaDNqPWQA==","signatures":[{"sig":"MEUCIBWTOglgmqxOyQP5XjxuEAzOReQuJxtVy46+5b8oGfsDAiEAkpk30nNa9yBj7rOhEnCFwrA5naAkuHGdMxfOTOFFCUw=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"index.js","_from":".","engines":{"gitbook":">=1.0.0"},"_npmUser":{"name":"samypesse","email":"samypesse@gmail.com"},"repository":{"url":"https://github.com/GitbookIO/plugin-exercises.git","type":"git"},"_npmVersion":"1.4.3","description":"Interactive exercices in a gitbook","directories":{}},"2.0.0-alpha.2":{"name":"gitbook-plugin-exercises","version":"2.0.0-alpha.2","license":"Apache 2","_id":"gitbook-plugin-exercises@2.0.0-alpha.2","maintainers":[{"name":"samypesse","email":"samypesse@gmail.com"}],"homepage":"https://github.com/GitbookIO/plugin-exercises","bugs":{"url":"https://github.com/GitbookIO/plugin-exercises/issues"},"dist":{"shasum":"d18cc3f181d3897391900cdf2c81e1375bbaf720","tarball":"https://registry.npmjs.org/gitbook-plugin-exercises/-/gitbook-plugin-exercises-2.0.0-alpha.2.tgz","integrity":"sha512-0nEjORuBC05+QP7Zvw4DzN4k56UdBjT2/VVu6CDXLYXTY1438flwJl4zOJ0rlZI2fnTV94voVod0bvoBfHHdrA==","signatures":[{"sig":"MEUCIFLigqhvplmFFPn+0Vi1YPji72JPODzcF0gvkaLvxuOEAiEA0f6PEMRZ8mRy/SXq61Sz5dejvE0K1O5FX6iWQB3sJG0=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"index.js","_from":".","_shasum":"d18cc3f181d3897391900cdf2c81e1375bbaf720","engines":{"gitbook":">1.x.x"},"gitHead":"96d0c7f767a39e71a7b75810fb97e76c59f9e1a1","scripts":{},"_npmUser":{"name":"samypesse","email":"samypesse@gmail.com"},"repository":{"url":"https://github.com/GitbookIO/plugin-exercises.git","type":"git"},"_npmVersion":"2.1.18","description":"Interactive exercices in a gitbook","directories":{},"_nodeVersion":"0.10.33","dependencies":{"kramed":"0.4.4","lodash":"3.0.1","kramed-markdown-renderer":"0.1.1"}},"2.0.0-alpha.3":{"name":"gitbook-plugin-exercises","version":"2.0.0-alpha.3","license":"Apache 2","_id":"gitbook-plugin-exercises@2.0.0-alpha.3","maintainers":[{"name":"samypesse","email":"samypesse@gmail.com"}],"homepage":"https://github.com/GitbookIO/plugin-exercises","bugs":{"url":"https://github.com/GitbookIO/plugin-exercises/issues"},"dist":{"shasum":"a41758b52fe7fdb37f0faf904079b6f2ee01270e","tarball":"https://registry.npmjs.org/gitbook-plugin-exercises/-/gitbook-plugin-exercises-2.0.0-alpha.3.tgz","integrity":"sha512-6OAz2kGOYucQzjsIWDvBbp9yLMEII4/ffzGPgB78zt97NFPZaUsfkUm1yCIuAzfmLnsdcG14+4M5QTYKLC5few==","signatures":[{"sig":"MEUCIQC1bzoRPffoUsycvErm59jwBFzqrCzxD6cUY/VQsCWAoQIgKYOoCONBGyDWD65Fh7ExLEbaPgxXv6CkUMVPEGlptbI=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"index.js","_from":".","_shasum":"a41758b52fe7fdb37f0faf904079b6f2ee01270e","engines":{"gitbook":">1.x.x"},"gitHead":"e5e50a6d5289913822bcdca7736bd085770192e2","scripts":{},"_npmUser":{"name":"samypesse","email":"samypesse@gmail.com"},"repository":{"url":"https://github.com/GitbookIO/plugin-exercises.git","type":"git"},"_npmVersion":"2.1.18","description":"Interactive exercices in a gitbook","directories":{},"_nodeVersion":"0.10.33","dependencies":{"kramed":"0.4.4","lodash":"3.0.1","kramed-markdown-renderer":"0.1.1"}},"2.1.0":{"name":"gitbook-plugin-exercises","version":"2.1.0","license":"Apache 2","_id":"gitbook-plugin-exercises@2.1.0","maintainers":[{"name":"jpreynat","email":"johan.preynat@gmail.com"},{"name":"samypesse","email":"samypesse@gmail.com"}],"homepage":"https://github.com/GitbookIO/plugin-exercises","bugs":{"url":"https://github.com/GitbookIO/plugin-exercises/issues"},"dist":{"shasum":"949cadc2a46e5b56e5129b6a90ab624c85a36571","tarball":"https://registry.npmjs.org/gitbook-plugin-exercises/-/gitbook-plugin-exercises-2.1.0.tgz","integrity":"sha512-L/V23xYLvQtYbxnsXkoPr7ifmlt+3JIY+mlxLnjO2r7yNF/YBriYPAS+uX02cwcdfcDEyeeGj0jtExgH175z7w==","signatures":[{"sig":"MEQCIHFpyFXhD2nY44/lsrtXLYtCu7Ulkd/gmbpokEx8Ih/pAiAqIZgvkzgPKazbvSudMWVkFTYuhCCGckEBKqAyx3P5Zw==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"index.js","_from":".","_shasum":"949cadc2a46e5b56e5129b6a90ab624c85a36571","engines":{"gitbook":">=3.0.0-pre.0"},"gitHead":"7ef17037feb58dea02392617e80b36239f83b880","scripts":{},"_npmUser":{"name":"jpreynat","email":"johan.preynat@gmail.com"},"repository":{"url":"git+https://github.com/GitbookIO/plugin-exercises.git","type":"git"},"_npmVersion":"3.7.3","description":"Interactive exercices in a gitbook","directories":{},"_nodeVersion":"5.9.0","dependencies":{"kramed":"0.4.4","lodash":"3.0.1","kramed-markdown-renderer":"0.1.1"},"_npmOperationalInternal":{"tmp":"tmp/gitbook-plugin-exercises-2.1.0.tgz_1461057878853_0.23158440203405917","host":"packages-16-east.internal.npmjs.com"}},"2.1.1":{"name":"gitbook-plugin-exercises","version":"2.1.1","license":"Apache 2","_id":"gitbook-plugin-exercises@2.1.1","maintainers":[{"name":"jpreynat","email":"johan.preynat@gmail.com"},{"name":"samypesse","email":"samypesse@gmail.com"}],"homepage":"https://github.com/GitbookIO/plugin-exercises","bugs":{"url":"https://github.com/GitbookIO/plugin-exercises/issues"},"dist":{"shasum":"04c73a30e20a64c1d5f3443db6f0e2550e0b3fb8","tarball":"https://registry.npmjs.org/gitbook-plugin-exercises/-/gitbook-plugin-exercises-2.1.1.tgz","integrity":"sha512-auiQH5NgaSNPv8XRrcOgywUkqil7Kf6WDLfUQlpM6tZ24YrJxnMEQq5BceqbN6fkuTblkcuOhKTFnhdBxJQuUg==","signatures":[{"sig":"MEYCIQCzfczTS2u4ejOhA6py9x9VH9E3m36hp6/h7NwWODIj5QIhALeBWqnTGNVQszJJa7qkra/DA1sRO2CwAAfz23AdnO7I","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"index.js","_from":".","_shasum":"04c73a30e20a64c1d5f3443db6f0e2550e0b3fb8","engines":{"gitbook":">=3.0.0-pre.0"},"gitHead":"36a95a2796f5cdc07da90de26c18917eca210231","scripts":{},"_npmUser":{"name":"jpreynat","email":"johan.preynat@gmail.com"},"repository":{"url":"git+https://github.com/GitbookIO/plugin-exercises.git","type":"git"},"_npmVersion":"3.7.3","description":"Interactive exercices in a gitbook","directories":{},"_nodeVersion":"5.9.0","dependencies":{"kramed":"0.4.4","lodash":"3.0.1","kramed-markdown-renderer":"0.1.1"},"_npmOperationalInternal":{"tmp":"tmp/gitbook-plugin-exercises-2.1.1.tgz_1462189240892_0.1683077395427972","host":"packages-12-west.internal.npmjs.com"}},"3.0.0":{"name":"gitbook-plugin-exercises","version":"3.0.0","license":"Apache 2","_id":"gitbook-plugin-exercises@3.0.0","maintainers":[{"name":"aarono","email":"aaron.omullan@gmail.com"},{"name":"gitbook-bot","email":"contact@gitbook.com"},{"name":"jpreynat","email":"johan.preynat@gmail.com"},{"name":"samypesse","email":"samypesse@gmail.com"},{"name":"soreine","email":"soreine.plume@gmail.com"}],"homepage":"https://github.com/GitbookIO/plugin-exercises","bugs":{"url":"https://github.com/GitbookIO/plugin-exercises/issues"},"dist":{"shasum":"540a1e157c040deae0ad3cdd8e3f5f830f4cd761","tarball":"https://registry.npmjs.org/gitbook-plugin-exercises/-/gitbook-plugin-exercises-3.0.0.tgz","integrity":"sha512-u7sRyLpJbc55/wVQf2GULKay9uq8SlhYviAyzyK7mcYXgXGE5HV1wVKcL07Xy9ljjXc+WjjPgm1RaDP6E86cWw==","signatures":[{"sig":"MEUCIEpYKfs6hMupTHGhOpr4vorKo+PEDoH1JR34VM0M4PQjAiEAgMGeLayAP4Dt+KX/Oqd/ugf/v73zeZi9Zkxz1axVhRM=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"index.js","_from":".","_shasum":"540a1e157c040deae0ad3cdd8e3f5f830f4cd761","engines":{"gitbook":">=3.0.0-pre.0"},"gitHead":"b29094b2794a6dff5b2f77d99299244284b7cb92","scripts":{},"_npmUser":{"name":"soreine","email":"soreine.plume@gmail.com"},"repository":{"url":"git+https://github.com/GitbookIO/plugin-exercises.git","type":"git"},"_npmVersion":"3.10.10","description":"Interactive exercices in a gitbook","directories":{},"_nodeVersion":"7.3.0","dependencies":{"lodash":"3.0.1"},"_npmOperationalInternal":{"tmp":"tmp/gitbook-plugin-exercises-3.0.0.tgz_1488539081517_0.17020434350706637","host":"packages-18-east.internal.npmjs.com"}}},"time":{"created":"2014-08-10T20:58:39.437Z","modified":"2026-03-31T14:08:46.029Z","0.0.0":"2014-08-10T20:58:39.437Z","1.0.0":"2014-08-20T05:03:55.142Z","2.0.0-alpha.1":"2015-02-02T20:54:33.820Z","2.0.0-alpha.2":"2015-02-02T21:01:13.723Z","2.0.0-alpha.3":"2015-02-14T15:46:42.566Z","2.1.0":"2016-04-19T09:24:40.116Z","2.1.1":"2016-05-02T11:40:43.558Z","3.0.0":"2017-03-03T11:04:42.281Z"},"bugs":{"url":"https://github.com/GitbookIO/plugin-exercises/issues"},"license":"Apache 2","homepage":"https://github.com/GitbookIO/plugin-exercises","repository":{"url":"git+https://github.com/GitbookIO/plugin-exercises.git","type":"git"},"description":"Interactive exercices in a gitbook","maintainers":[{"email":"contact@gitbook.com","name":"gitbook-bot"},{"email":"samypesse@gmail.com","name":"samypesse"},{"email":"johan.preynat@gmail.com","name":"jpreynat"},{"email":"shne24@gmail.com","name":"emmerich"},{"email":"taranvohra@outlook.com","name":"taranvohra"},{"email":"nolann.biron@ynov.com","name":"nolannb"},{"email":"berge.greg@gmail.com","name":"neoziro"},{"email":"admin@zeno.zone","name":"zenoachtig"}],"readme":"Interactive exercises in a gitbook\n==============\n\nWith this plugin, a book can contain interactive exercises (currently only in Javascript). An exercise is a code challenge provided to the reader, who is given a code editor to write a solution which is checked against the book author's validation code.\n\n## How to use it?\n\nTo use the exercises plugin in your Gitbook project, add the `exercises` plugin to the `book.json` file, then install plugins using `gitbook install`.\n\n```\n{\n    \"plugins\": [\"exercises\"]\n}\n```\n\n## Exercises format\n\nAn exercise is defined by 4 simple parts:\n\n* Exercise **Message**/Goals (in markdown/text)\n* **Initial** code to show to the user, providing a starting point\n* **Solution** code, being a correct solution to the exercise\n* **Validation** code that tests the correctness of the user's input\n* **Context** (optional) code evaluated before executing the user's solution\n\n```\n{% exercise %}\nDefine a variable `x` equal to 10.\n\n{% initial %}\nvar x =\n\n{% solution %}\nvar x = 10;\n\n{% validation %}\nassert(x == 10);\n\n{% context %}\n// This is context code available everywhere\n// The user will be able to evaluate `exposedVar`\nvar exposedVar = 3;\n// ... or call `exposedFunction`\nfunction exposedFunction {\n    return 3;\n}\n{% endexercise %}\n```\n\n**The old format (`gitbook < 2.0.0`) is no longer supported.**\n","readmeFilename":"README.md","users":{"a1ip":true,"runuyty":true,"justpilz":true,"urbantumbleweed":true}}