├── .babelrc ├── .gitignore ├── .prettierrc ├── README.md ├── package.json ├── playground ├── app.tsx ├── index.html └── vite.config.js ├── pnpm-lock.yaml ├── rollup.config.js ├── src └── solid-repl.tsx └── tsconfig.json /.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": ["babel-preset-solid", "@babel/preset-typescript"] 3 | } -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | dist 2 | node_modules 3 | .parcel-cache 4 | .cache -------------------------------------------------------------------------------- /.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "arrowParens": "always", 3 | "bracketSpacing": true, 4 | "endOfLine": "lf", 5 | "htmlWhitespaceSensitivity": "ignore", 6 | "jsxSingleQuote": false, 7 | "printWidth": 80, 8 | "quoteProps": "as-needed", 9 | "semi": true, 10 | "singleQuote": true, 11 | "trailingComma": "all", 12 | "tabWidth": 2, 13 | "useTabs": false 14 | } 15 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 2 | 3 | # Solid REPL 4 | 5 | > ## /!\ This repo. is temporarly innactive. All of the work around both the REPL and the playground is taking place over at [https://github.com/solidjs/solid-playground](https://github.com/solidjs/solid-playground) 6 | 7 | A re-usable [solid](https://github.com/ryansolid/solid) component that provides an embedable REPL. 8 | 9 | - [Solid REPL](#solid-repl) 10 | - [Usage](#usage) 11 | - [Installation](#installation) 12 | - [In practice](#in-practice) 13 | - [Options](#options) 14 | - [Repl options](#repl-options) 15 | - [ReplTab options](#repltab-options) 16 | - [Contributing](#contributing) 17 | - [Technical details](#technical-details) 18 | - [How does it work?](#how-does-it-work) 19 | - [TODOs](#todos) 20 | - [Credits](#credits) 21 | 22 | ## Usage 23 | 24 | [Demo available here](https://codesandbox.io/s/solid-repl-example-xr6de?file=/src/index.tsx) 25 | 26 | ### Installation 27 | 28 | ```bash 29 | # npm 30 | npm install solid-repl 31 | 32 | # pnpm 33 | pnpm add solid-repl 34 | 35 | # yarn 36 | yarn add solid-repl 37 | ``` 38 | 39 | ### In practice 40 | 41 | In a nutshell this is how you'd use it: 42 | 43 | ```tsx 44 | import { Repl, ReplTab } from 'solid-repl'; 45 | import { render } from 'solid-js/web'; 46 | 47 | const App = () => { 48 | return ( 49 | 55 | 56 | {` 57 | import { render } from 'solid-js/web'; 58 | import { App } from './app.tsx'; 59 | 60 | render(App, document.getElementById('app')); 61 | `} 62 | 63 | 64 | {'export const App = () =>

Hello world

'} 65 |
66 |
67 | ); 68 | }; 69 | 70 | render(App, document.getElementById('app')!); 71 | ``` 72 | 73 | ### Options 74 | 75 | #### Repl options 76 | 77 | | name | required | type | default | description | 78 | | --------------- | -------- | ------- | --------------------------------- | --------------------------------- | 79 | | `baseUrl` | false | string | `https://playground.solidjs.com/` | The source of the iframe | 80 | | `height` | false | number | `250` | The height in pixel | 81 | | `withHeader` | false | boolean | `false` | Whether to show or not | 82 | | `isInteractive` | false | boolean | `false` | Whether it's interactive or not | 83 | 84 | #### ReplTab options 85 | 86 | | name | required | type | default | description | 87 | | ------ | -------- | ------ | ------- | --------------- | 88 | | `name` | true | string | - | Name of the tab | 89 | 90 | ## Contributing 91 | 92 | This project uses the [pnpm](https://pnpm.js.org/) package manager. You should install this one if you want to contribute. 93 | This project uses [prettier](https://prettier.io/) to format code. A `format` npm script can be used to format the code. 94 | 95 | In order to contribute you can : 96 | 97 | 1. Clone the reposotory: `git clone git@github.com:ryansolid/solid-repl.git` 98 | 2. Install the dependencies: `pnpm install` 99 | 3. Operate you changes: `pnpm test` will load a live server to preview your changes on [http://localhost:1234](http://localhost:1234) 100 | 4. (optional) Run `pnpm format` to format the code if you don't have that automatically in your IDE 101 | 102 | ## Technical details 103 | 104 | This package is a simple wrapper around the [solid playground](https://github.com/ryansolid/solid-playground) as an iframe. 105 | **The below information are related to the solid-playground of the iframe.** 106 | 107 | ### How does it work? 108 | 109 | Basically, each "tab" acts as a virtual file. This virtual file system is represented by a global array of tabs. 110 | 111 | On every tab source change, rollup parses all the file and create an ESM bundle. This ESM bundle is injected into an iframe with a ` 11 | 12 | 13 | -------------------------------------------------------------------------------- /playground/vite.config.js: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite'; 2 | import solidPlugin from 'vite-plugin-solid'; 3 | 4 | export default defineConfig({ 5 | plugins: [solidPlugin()], 6 | }); 7 | -------------------------------------------------------------------------------- /pnpm-lock.yaml: -------------------------------------------------------------------------------- 1 | lockfileVersion: 5.3 2 | 3 | specifiers: 4 | '@amoutonbrady/lz-string': ^0.0.1 5 | prettier: ^2.3.0 6 | rollup: ^2.47.0 7 | rollup-preset-solid: ^0.3.0 8 | solid-js: ^0.26.5 9 | typescript: ^4.2.4 10 | vite: ^2.3.2 11 | vite-plugin-solid: ^1.8.0 12 | 13 | dependencies: 14 | '@amoutonbrady/lz-string': 0.0.1 15 | solid-js: 0.26.5 16 | 17 | devDependencies: 18 | prettier: 2.3.0 19 | rollup: 2.47.0 20 | rollup-preset-solid: 0.3.0 21 | typescript: 4.2.4 22 | vite: 2.3.2 23 | vite-plugin-solid: 1.8.0 24 | 25 | packages: 26 | 27 | /@amoutonbrady/lz-string/0.0.1: 28 | resolution: {integrity: sha512-crH4ovRiiTg9y1lDTEtMwTdD4s/aYoz4EemUD3p+9GvHMOeJ3tUXQ/DQM1Mw9/wc9Od4jG97w0m9+gZmLysGFQ==} 29 | dev: false 30 | 31 | /@babel/code-frame/7.12.13: 32 | resolution: {integrity: sha512-HV1Cm0Q3ZrpCR93tkWOYiuYIgLxZXZFVG2VgK+MBWjUqZTundupbfx2aXarXuw5Ko5aMcjtJgbSs4vUGBS5v6g==} 33 | dependencies: 34 | '@babel/highlight': 7.14.0 35 | dev: true 36 | 37 | /@babel/compat-data/7.14.0: 38 | resolution: {integrity: sha512-vu9V3uMM/1o5Hl5OekMUowo3FqXLJSw+s+66nt0fSWVWTtmosdzn45JHOB3cPtZoe6CTBDzvSw0RdOY85Q37+Q==} 39 | dev: true 40 | 41 | /@babel/core/7.14.0: 42 | resolution: {integrity: sha512-8YqpRig5NmIHlMLw09zMlPTvUVMILjqCOtVgu+TVNWEBvy9b5I3RRyhqnrV4hjgEK7n8P9OqvkWJAFmEL6Wwfw==} 43 | engines: {node: '>=6.9.0'} 44 | dependencies: 45 | '@babel/code-frame': 7.12.13 46 | '@babel/generator': 7.14.1 47 | '@babel/helper-compilation-targets': 7.13.16_@babel+core@7.14.0 48 | '@babel/helper-module-transforms': 7.14.0 49 | '@babel/helpers': 7.14.0 50 | '@babel/parser': 7.14.1 51 | '@babel/template': 7.12.13 52 | '@babel/traverse': 7.14.0 53 | '@babel/types': 7.14.1 54 | convert-source-map: 1.7.0 55 | debug: 4.3.1 56 | gensync: 1.0.0-beta.2 57 | json5: 2.2.0 58 | semver: 6.3.0 59 | source-map: 0.5.7 60 | transitivePeerDependencies: 61 | - supports-color 62 | dev: true 63 | 64 | /@babel/core/7.14.2: 65 | resolution: {integrity: sha512-OgC1mON+l4U4B4wiohJlQNUU3H73mpTyYY3j/c8U9dr9UagGGSm+WFpzjy/YLdoyjiG++c1kIDgxCo/mLwQJeQ==} 66 | engines: {node: '>=6.9.0'} 67 | dependencies: 68 | '@babel/code-frame': 7.12.13 69 | '@babel/generator': 7.14.2 70 | '@babel/helper-compilation-targets': 7.13.16_@babel+core@7.14.2 71 | '@babel/helper-module-transforms': 7.14.2 72 | '@babel/helpers': 7.14.0 73 | '@babel/parser': 7.14.2 74 | '@babel/template': 7.12.13 75 | '@babel/traverse': 7.14.2 76 | '@babel/types': 7.14.2 77 | convert-source-map: 1.7.0 78 | debug: 4.3.1 79 | gensync: 1.0.0-beta.2 80 | json5: 2.2.0 81 | semver: 6.3.0 82 | source-map: 0.5.7 83 | transitivePeerDependencies: 84 | - supports-color 85 | dev: true 86 | 87 | /@babel/generator/7.14.1: 88 | resolution: {integrity: sha512-TMGhsXMXCP/O1WtQmZjpEYDhCYC9vFhayWZPJSZCGkPJgUqX0rF0wwtrYvnzVxIjcF80tkUertXVk5cwqi5cAQ==} 89 | dependencies: 90 | '@babel/types': 7.14.1 91 | jsesc: 2.5.2 92 | source-map: 0.5.7 93 | dev: true 94 | 95 | /@babel/generator/7.14.2: 96 | resolution: {integrity: sha512-OnADYbKrffDVai5qcpkMxQ7caomHOoEwjkouqnN2QhydAjowFAZcsdecFIRUBdb+ZcruwYE4ythYmF1UBZU5xQ==} 97 | dependencies: 98 | '@babel/types': 7.14.2 99 | jsesc: 2.5.2 100 | source-map: 0.5.7 101 | dev: true 102 | 103 | /@babel/helper-annotate-as-pure/7.12.13: 104 | resolution: {integrity: sha512-7YXfX5wQ5aYM/BOlbSccHDbuXXFPxeoUmfWtz8le2yTkTZc+BxsiEnENFoi2SlmA8ewDkG2LgIMIVzzn2h8kfw==} 105 | dependencies: 106 | '@babel/types': 7.14.1 107 | dev: true 108 | 109 | /@babel/helper-compilation-targets/7.13.16_@babel+core@7.14.0: 110 | resolution: {integrity: sha512-3gmkYIrpqsLlieFwjkGgLaSHmhnvlAYzZLlYVjlW+QwI+1zE17kGxuJGmIqDQdYp56XdmGeD+Bswx0UTyG18xA==} 111 | peerDependencies: 112 | '@babel/core': ^7.0.0 113 | dependencies: 114 | '@babel/compat-data': 7.14.0 115 | '@babel/core': 7.14.0 116 | '@babel/helper-validator-option': 7.12.17 117 | browserslist: 4.16.6 118 | semver: 6.3.0 119 | dev: true 120 | 121 | /@babel/helper-compilation-targets/7.13.16_@babel+core@7.14.2: 122 | resolution: {integrity: sha512-3gmkYIrpqsLlieFwjkGgLaSHmhnvlAYzZLlYVjlW+QwI+1zE17kGxuJGmIqDQdYp56XdmGeD+Bswx0UTyG18xA==} 123 | peerDependencies: 124 | '@babel/core': ^7.0.0 125 | dependencies: 126 | '@babel/compat-data': 7.14.0 127 | '@babel/core': 7.14.2 128 | '@babel/helper-validator-option': 7.12.17 129 | browserslist: 4.16.6 130 | semver: 6.3.0 131 | dev: true 132 | 133 | /@babel/helper-create-class-features-plugin/7.14.1_@babel+core@7.14.0: 134 | resolution: {integrity: sha512-r8rsUahG4ywm0QpGcCrLaUSOuNAISR3IZCg4Fx05Ozq31aCUrQsTLH6KPxy0N5ULoQ4Sn9qjNdGNtbPWAC6hYg==} 135 | peerDependencies: 136 | '@babel/core': ^7.0.0 137 | dependencies: 138 | '@babel/core': 7.14.0 139 | '@babel/helper-annotate-as-pure': 7.12.13 140 | '@babel/helper-function-name': 7.12.13 141 | '@babel/helper-member-expression-to-functions': 7.13.12 142 | '@babel/helper-optimise-call-expression': 7.12.13 143 | '@babel/helper-replace-supers': 7.13.12 144 | '@babel/helper-split-export-declaration': 7.12.13 145 | transitivePeerDependencies: 146 | - supports-color 147 | dev: true 148 | 149 | /@babel/helper-create-class-features-plugin/7.14.1_@babel+core@7.14.2: 150 | resolution: {integrity: sha512-r8rsUahG4ywm0QpGcCrLaUSOuNAISR3IZCg4Fx05Ozq31aCUrQsTLH6KPxy0N5ULoQ4Sn9qjNdGNtbPWAC6hYg==} 151 | peerDependencies: 152 | '@babel/core': ^7.0.0 153 | dependencies: 154 | '@babel/core': 7.14.2 155 | '@babel/helper-annotate-as-pure': 7.12.13 156 | '@babel/helper-function-name': 7.12.13 157 | '@babel/helper-member-expression-to-functions': 7.13.12 158 | '@babel/helper-optimise-call-expression': 7.12.13 159 | '@babel/helper-replace-supers': 7.13.12 160 | '@babel/helper-split-export-declaration': 7.12.13 161 | transitivePeerDependencies: 162 | - supports-color 163 | dev: true 164 | 165 | /@babel/helper-function-name/7.12.13: 166 | resolution: {integrity: sha512-TZvmPn0UOqmvi5G4vvw0qZTpVptGkB1GL61R6lKvrSdIxGm5Pky7Q3fpKiIkQCAtRCBUwB0PaThlx9vebCDSwA==} 167 | dependencies: 168 | '@babel/helper-get-function-arity': 7.12.13 169 | '@babel/template': 7.12.13 170 | '@babel/types': 7.14.1 171 | dev: true 172 | 173 | /@babel/helper-function-name/7.14.2: 174 | resolution: {integrity: sha512-NYZlkZRydxw+YT56IlhIcS8PAhb+FEUiOzuhFTfqDyPmzAhRge6ua0dQYT/Uh0t/EDHq05/i+e5M2d4XvjgarQ==} 175 | dependencies: 176 | '@babel/helper-get-function-arity': 7.12.13 177 | '@babel/template': 7.12.13 178 | '@babel/types': 7.14.2 179 | dev: true 180 | 181 | /@babel/helper-get-function-arity/7.12.13: 182 | resolution: {integrity: sha512-DjEVzQNz5LICkzN0REdpD5prGoidvbdYk1BVgRUOINaWJP2t6avB27X1guXK1kXNrX0WMfsrm1A/ZBthYuIMQg==} 183 | dependencies: 184 | '@babel/types': 7.14.2 185 | dev: true 186 | 187 | /@babel/helper-member-expression-to-functions/7.13.12: 188 | resolution: {integrity: sha512-48ql1CLL59aKbU94Y88Xgb2VFy7a95ykGRbJJaaVv+LX5U8wFpLfiGXJJGUozsmA1oEh/o5Bp60Voq7ACyA/Sw==} 189 | dependencies: 190 | '@babel/types': 7.14.1 191 | dev: true 192 | 193 | /@babel/helper-module-imports/7.13.12: 194 | resolution: {integrity: sha512-4cVvR2/1B693IuOvSI20xqqa/+bl7lqAMR59R4iu39R9aOX8/JoYY1sFaNvUMyMBGnHdwvJgUrzNLoUZxXypxA==} 195 | dependencies: 196 | '@babel/types': 7.14.1 197 | dev: true 198 | 199 | /@babel/helper-module-transforms/7.14.0: 200 | resolution: {integrity: sha512-L40t9bxIuGOfpIGA3HNkJhU9qYrf4y5A5LUSw7rGMSn+pcG8dfJ0g6Zval6YJGd2nEjI7oP00fRdnhLKndx6bw==} 201 | dependencies: 202 | '@babel/helper-module-imports': 7.13.12 203 | '@babel/helper-replace-supers': 7.13.12 204 | '@babel/helper-simple-access': 7.13.12 205 | '@babel/helper-split-export-declaration': 7.12.13 206 | '@babel/helper-validator-identifier': 7.14.0 207 | '@babel/template': 7.12.13 208 | '@babel/traverse': 7.14.0 209 | '@babel/types': 7.14.1 210 | transitivePeerDependencies: 211 | - supports-color 212 | dev: true 213 | 214 | /@babel/helper-module-transforms/7.14.2: 215 | resolution: {integrity: sha512-OznJUda/soKXv0XhpvzGWDnml4Qnwp16GN+D/kZIdLsWoHj05kyu8Rm5kXmMef+rVJZ0+4pSGLkeixdqNUATDA==} 216 | dependencies: 217 | '@babel/helper-module-imports': 7.13.12 218 | '@babel/helper-replace-supers': 7.13.12 219 | '@babel/helper-simple-access': 7.13.12 220 | '@babel/helper-split-export-declaration': 7.12.13 221 | '@babel/helper-validator-identifier': 7.14.0 222 | '@babel/template': 7.12.13 223 | '@babel/traverse': 7.14.2 224 | '@babel/types': 7.14.2 225 | transitivePeerDependencies: 226 | - supports-color 227 | dev: true 228 | 229 | /@babel/helper-optimise-call-expression/7.12.13: 230 | resolution: {integrity: sha512-BdWQhoVJkp6nVjB7nkFWcn43dkprYauqtk++Py2eaf/GRDFm5BxRqEIZCiHlZUGAVmtwKcsVL1dC68WmzeFmiA==} 231 | dependencies: 232 | '@babel/types': 7.14.1 233 | dev: true 234 | 235 | /@babel/helper-plugin-utils/7.13.0: 236 | resolution: {integrity: sha512-ZPafIPSwzUlAoWT8DKs1W2VyF2gOWthGd5NGFMsBcMMol+ZhK+EQY/e6V96poa6PA/Bh+C9plWN0hXO1uB8AfQ==} 237 | dev: true 238 | 239 | /@babel/helper-replace-supers/7.13.12: 240 | resolution: {integrity: sha512-Gz1eiX+4yDO8mT+heB94aLVNCL+rbuT2xy4YfyNqu8F+OI6vMvJK891qGBTqL9Uc8wxEvRW92Id6G7sDen3fFw==} 241 | dependencies: 242 | '@babel/helper-member-expression-to-functions': 7.13.12 243 | '@babel/helper-optimise-call-expression': 7.12.13 244 | '@babel/traverse': 7.14.0 245 | '@babel/types': 7.14.1 246 | transitivePeerDependencies: 247 | - supports-color 248 | dev: true 249 | 250 | /@babel/helper-simple-access/7.13.12: 251 | resolution: {integrity: sha512-7FEjbrx5SL9cWvXioDbnlYTppcZGuCY6ow3/D5vMggb2Ywgu4dMrpTJX0JdQAIcRRUElOIxF3yEooa9gUb9ZbA==} 252 | dependencies: 253 | '@babel/types': 7.14.1 254 | dev: true 255 | 256 | /@babel/helper-split-export-declaration/7.12.13: 257 | resolution: {integrity: sha512-tCJDltF83htUtXx5NLcaDqRmknv652ZWCHyoTETf1CXYJdPC7nohZohjUgieXhv0hTJdRf2FjDueFehdNucpzg==} 258 | dependencies: 259 | '@babel/types': 7.14.1 260 | dev: true 261 | 262 | /@babel/helper-validator-identifier/7.14.0: 263 | resolution: {integrity: sha512-V3ts7zMSu5lfiwWDVWzRDGIN+lnCEUdaXgtVHJgLb1rGaA6jMrtB9EmE7L18foXJIE8Un/A/h6NJfGQp/e1J4A==} 264 | dev: true 265 | 266 | /@babel/helper-validator-option/7.12.17: 267 | resolution: {integrity: sha512-TopkMDmLzq8ngChwRlyjR6raKD6gMSae4JdYDB8bByKreQgG0RBTuKe9LRxW3wFtUnjxOPRKBDwEH6Mg5KeDfw==} 268 | dev: true 269 | 270 | /@babel/helpers/7.14.0: 271 | resolution: {integrity: sha512-+ufuXprtQ1D1iZTO/K9+EBRn+qPWMJjZSw/S0KlFrxCw4tkrzv9grgpDHkY9MeQTjTY8i2sp7Jep8DfU6tN9Mg==} 272 | dependencies: 273 | '@babel/template': 7.12.13 274 | '@babel/traverse': 7.14.0 275 | '@babel/types': 7.14.1 276 | transitivePeerDependencies: 277 | - supports-color 278 | dev: true 279 | 280 | /@babel/highlight/7.14.0: 281 | resolution: {integrity: sha512-YSCOwxvTYEIMSGaBQb5kDDsCopDdiUGsqpatp3fOlI4+2HQSkTmEVWnVuySdAC5EWCqSWWTv0ib63RjR7dTBdg==} 282 | dependencies: 283 | '@babel/helper-validator-identifier': 7.14.0 284 | chalk: 2.4.2 285 | js-tokens: 4.0.0 286 | dev: true 287 | 288 | /@babel/parser/7.14.1: 289 | resolution: {integrity: sha512-muUGEKu8E/ftMTPlNp+mc6zL3E9zKWmF5sDHZ5MSsoTP9Wyz64AhEf9kD08xYJ7w6Hdcu8H550ircnPyWSIF0Q==} 290 | engines: {node: '>=6.0.0'} 291 | hasBin: true 292 | dev: true 293 | 294 | /@babel/parser/7.14.2: 295 | resolution: {integrity: sha512-IoVDIHpsgE/fu7eXBeRWt8zLbDrSvD7H1gpomOkPpBoEN8KCruCqSDdqo8dddwQQrui30KSvQBaMUOJiuFu6QQ==} 296 | engines: {node: '>=6.0.0'} 297 | hasBin: true 298 | dev: true 299 | 300 | /@babel/plugin-syntax-jsx/7.12.13_@babel+core@7.14.0: 301 | resolution: {integrity: sha512-d4HM23Q1K7oq/SLNmG6mRt85l2csmQ0cHRaxRXjKW0YFdEXqlZ5kzFQKH5Uc3rDJECgu+yCRgPkG04Mm98R/1g==} 302 | peerDependencies: 303 | '@babel/core': ^7.0.0-0 304 | dependencies: 305 | '@babel/core': 7.14.0 306 | '@babel/helper-plugin-utils': 7.13.0 307 | dev: true 308 | 309 | /@babel/plugin-syntax-jsx/7.12.13_@babel+core@7.14.2: 310 | resolution: {integrity: sha512-d4HM23Q1K7oq/SLNmG6mRt85l2csmQ0cHRaxRXjKW0YFdEXqlZ5kzFQKH5Uc3rDJECgu+yCRgPkG04Mm98R/1g==} 311 | peerDependencies: 312 | '@babel/core': ^7.0.0-0 313 | dependencies: 314 | '@babel/core': 7.14.2 315 | '@babel/helper-plugin-utils': 7.13.0 316 | dev: true 317 | 318 | /@babel/plugin-syntax-typescript/7.12.13_@babel+core@7.14.0: 319 | resolution: {integrity: sha512-cHP3u1JiUiG2LFDKbXnwVad81GvfyIOmCD6HIEId6ojrY0Drfy2q1jw7BwN7dE84+kTnBjLkXoL3IEy/3JPu2w==} 320 | peerDependencies: 321 | '@babel/core': ^7.0.0-0 322 | dependencies: 323 | '@babel/core': 7.14.0 324 | '@babel/helper-plugin-utils': 7.13.0 325 | dev: true 326 | 327 | /@babel/plugin-syntax-typescript/7.12.13_@babel+core@7.14.2: 328 | resolution: {integrity: sha512-cHP3u1JiUiG2LFDKbXnwVad81GvfyIOmCD6HIEId6ojrY0Drfy2q1jw7BwN7dE84+kTnBjLkXoL3IEy/3JPu2w==} 329 | peerDependencies: 330 | '@babel/core': ^7.0.0-0 331 | dependencies: 332 | '@babel/core': 7.14.2 333 | '@babel/helper-plugin-utils': 7.13.0 334 | dev: true 335 | 336 | /@babel/plugin-transform-typescript/7.13.0_@babel+core@7.14.0: 337 | resolution: {integrity: sha512-elQEwluzaU8R8dbVuW2Q2Y8Nznf7hnjM7+DSCd14Lo5fF63C9qNLbwZYbmZrtV9/ySpSUpkRpQXvJb6xyu4hCQ==} 338 | peerDependencies: 339 | '@babel/core': ^7.0.0-0 340 | dependencies: 341 | '@babel/core': 7.14.0 342 | '@babel/helper-create-class-features-plugin': 7.14.1_@babel+core@7.14.0 343 | '@babel/helper-plugin-utils': 7.13.0 344 | '@babel/plugin-syntax-typescript': 7.12.13_@babel+core@7.14.0 345 | transitivePeerDependencies: 346 | - supports-color 347 | dev: true 348 | 349 | /@babel/plugin-transform-typescript/7.13.0_@babel+core@7.14.2: 350 | resolution: {integrity: sha512-elQEwluzaU8R8dbVuW2Q2Y8Nznf7hnjM7+DSCd14Lo5fF63C9qNLbwZYbmZrtV9/ySpSUpkRpQXvJb6xyu4hCQ==} 351 | peerDependencies: 352 | '@babel/core': ^7.0.0-0 353 | dependencies: 354 | '@babel/core': 7.14.2 355 | '@babel/helper-create-class-features-plugin': 7.14.1_@babel+core@7.14.2 356 | '@babel/helper-plugin-utils': 7.13.0 357 | '@babel/plugin-syntax-typescript': 7.12.13_@babel+core@7.14.2 358 | transitivePeerDependencies: 359 | - supports-color 360 | dev: true 361 | 362 | /@babel/preset-typescript/7.13.0_@babel+core@7.14.0: 363 | resolution: {integrity: sha512-LXJwxrHy0N3f6gIJlYbLta1D9BDtHpQeqwzM0LIfjDlr6UE/D5Mc7W4iDiQzaE+ks0sTjT26ArcHWnJVt0QiHw==} 364 | peerDependencies: 365 | '@babel/core': ^7.0.0-0 366 | dependencies: 367 | '@babel/core': 7.14.0 368 | '@babel/helper-plugin-utils': 7.13.0 369 | '@babel/helper-validator-option': 7.12.17 370 | '@babel/plugin-transform-typescript': 7.13.0_@babel+core@7.14.0 371 | transitivePeerDependencies: 372 | - supports-color 373 | dev: true 374 | 375 | /@babel/preset-typescript/7.13.0_@babel+core@7.14.2: 376 | resolution: {integrity: sha512-LXJwxrHy0N3f6gIJlYbLta1D9BDtHpQeqwzM0LIfjDlr6UE/D5Mc7W4iDiQzaE+ks0sTjT26ArcHWnJVt0QiHw==} 377 | peerDependencies: 378 | '@babel/core': ^7.0.0-0 379 | dependencies: 380 | '@babel/core': 7.14.2 381 | '@babel/helper-plugin-utils': 7.13.0 382 | '@babel/helper-validator-option': 7.12.17 383 | '@babel/plugin-transform-typescript': 7.13.0_@babel+core@7.14.2 384 | transitivePeerDependencies: 385 | - supports-color 386 | dev: true 387 | 388 | /@babel/template/7.12.13: 389 | resolution: {integrity: sha512-/7xxiGA57xMo/P2GVvdEumr8ONhFOhfgq2ihK3h1e6THqzTAkHbkXgB0xI9yeTfIUoH3+oAeHhqm/I43OTbbjA==} 390 | dependencies: 391 | '@babel/code-frame': 7.12.13 392 | '@babel/parser': 7.14.1 393 | '@babel/types': 7.14.1 394 | dev: true 395 | 396 | /@babel/traverse/7.14.0: 397 | resolution: {integrity: sha512-dZ/a371EE5XNhTHomvtuLTUyx6UEoJmYX+DT5zBCQN3McHemsuIaKKYqsc/fs26BEkHs/lBZy0J571LP5z9kQA==} 398 | dependencies: 399 | '@babel/code-frame': 7.12.13 400 | '@babel/generator': 7.14.1 401 | '@babel/helper-function-name': 7.12.13 402 | '@babel/helper-split-export-declaration': 7.12.13 403 | '@babel/parser': 7.14.1 404 | '@babel/types': 7.14.1 405 | debug: 4.3.1 406 | globals: 11.12.0 407 | transitivePeerDependencies: 408 | - supports-color 409 | dev: true 410 | 411 | /@babel/traverse/7.14.2: 412 | resolution: {integrity: sha512-TsdRgvBFHMyHOOzcP9S6QU0QQtjxlRpEYOy3mcCO5RgmC305ki42aSAmfZEMSSYBla2oZ9BMqYlncBaKmD/7iA==} 413 | dependencies: 414 | '@babel/code-frame': 7.12.13 415 | '@babel/generator': 7.14.2 416 | '@babel/helper-function-name': 7.14.2 417 | '@babel/helper-split-export-declaration': 7.12.13 418 | '@babel/parser': 7.14.2 419 | '@babel/types': 7.14.2 420 | debug: 4.3.1 421 | globals: 11.12.0 422 | transitivePeerDependencies: 423 | - supports-color 424 | dev: true 425 | 426 | /@babel/types/7.14.1: 427 | resolution: {integrity: sha512-S13Qe85fzLs3gYRUnrpyeIrBJIMYv33qSTg1qoBwiG6nPKwUWAD9odSzWhEedpwOIzSEI6gbdQIWEMiCI42iBA==} 428 | dependencies: 429 | '@babel/helper-validator-identifier': 7.14.0 430 | to-fast-properties: 2.0.0 431 | dev: true 432 | 433 | /@babel/types/7.14.2: 434 | resolution: {integrity: sha512-SdjAG/3DikRHpUOjxZgnkbR11xUlyDMUFJdvnIgZEE16mqmY0BINMmc4//JMJglEmn6i7sq6p+mGrFWyZ98EEw==} 435 | dependencies: 436 | '@babel/helper-validator-identifier': 7.14.0 437 | to-fast-properties: 2.0.0 438 | dev: true 439 | 440 | /@rollup/plugin-babel/5.3.0_@babel+core@7.14.0+rollup@2.47.0: 441 | resolution: {integrity: sha512-9uIC8HZOnVLrLHxayq/PTzw+uS25E14KPUBh5ktF+18Mjo5yK0ToMMx6epY0uEgkjwJw0aBW4x2horYXh8juWw==} 442 | engines: {node: '>= 10.0.0'} 443 | peerDependencies: 444 | '@babel/core': ^7.0.0 445 | '@types/babel__core': ^7.1.9 446 | rollup: ^1.20.0||^2.0.0 447 | peerDependenciesMeta: 448 | '@types/babel__core': 449 | optional: true 450 | dependencies: 451 | '@babel/core': 7.14.0 452 | '@babel/helper-module-imports': 7.13.12 453 | '@rollup/pluginutils': 3.1.0_rollup@2.47.0 454 | rollup: 2.47.0 455 | dev: true 456 | 457 | /@rollup/plugin-node-resolve/11.2.1_rollup@2.47.0: 458 | resolution: {integrity: sha512-yc2n43jcqVyGE2sqV5/YCmocy9ArjVAP/BeXyTtADTBBX6V0e5UMqwO8CdQ0kzjb6zu5P1qMzsScCMRvE9OlVg==} 459 | engines: {node: '>= 10.0.0'} 460 | peerDependencies: 461 | rollup: ^1.20.0||^2.0.0 462 | dependencies: 463 | '@rollup/pluginutils': 3.1.0_rollup@2.47.0 464 | '@types/resolve': 1.17.1 465 | builtin-modules: 3.2.0 466 | deepmerge: 4.2.2 467 | is-module: 1.0.0 468 | resolve: 1.20.0 469 | rollup: 2.47.0 470 | dev: true 471 | 472 | /@rollup/pluginutils/3.1.0_rollup@2.47.0: 473 | resolution: {integrity: sha512-GksZ6pr6TpIjHm8h9lSQ8pi8BE9VeubNT0OMJ3B5uZJ8pz73NPiqOtCog/x2/QzM1ENChPKxMDhiQuRHsqc+lg==} 474 | engines: {node: '>= 8.0.0'} 475 | peerDependencies: 476 | rollup: ^1.20.0||^2.0.0 477 | dependencies: 478 | '@types/estree': 0.0.39 479 | estree-walker: 1.0.1 480 | picomatch: 2.2.3 481 | rollup: 2.47.0 482 | dev: true 483 | 484 | /@types/estree/0.0.39: 485 | resolution: {integrity: sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw==} 486 | dev: true 487 | 488 | /@types/node/15.0.1: 489 | resolution: {integrity: sha512-TMkXt0Ck1y0KKsGr9gJtWGjttxlZnnvDtphxUOSd0bfaR6Q1jle+sPvrzNR1urqYTWMinoKvjKfXUGsumaO1PA==} 490 | dev: true 491 | 492 | /@types/resolve/1.17.1: 493 | resolution: {integrity: sha512-yy7HuzQhj0dhGpD8RLXSZWEkLsV9ibvxvi6EiJ3bkqLAO1RGo0WbkWQiwpRlSFymTJRz0d3k5LM3kkx8ArDbLw==} 494 | dependencies: 495 | '@types/node': 15.0.1 496 | dev: true 497 | 498 | /ansi-styles/3.2.1: 499 | resolution: {integrity: sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==} 500 | engines: {node: '>=4'} 501 | dependencies: 502 | color-convert: 1.9.3 503 | dev: true 504 | 505 | /babel-plugin-jsx-dom-expressions/0.25.16_@babel+core@7.14.0: 506 | resolution: {integrity: sha512-yvfjb0xeVVzWCbFkrr3Yx/cJBLh5izv9JuMLXu2u9GX1+oWvdg6CKRs62ZFUKHLeRu7lJKMdW0GIXXNJigRdFw==} 507 | dependencies: 508 | '@babel/helper-module-imports': 7.13.12 509 | '@babel/plugin-syntax-jsx': 7.12.13_@babel+core@7.14.0 510 | '@babel/types': 7.14.1 511 | transitivePeerDependencies: 512 | - '@babel/core' 513 | dev: true 514 | 515 | /babel-plugin-jsx-dom-expressions/0.26.3_@babel+core@7.14.2: 516 | resolution: {integrity: sha512-TtcqjKrCzP9m8eMKBTxwdqTK5PlySn6+mYt6vJTbgQ7cCNtnurLUqPFN+ObG1dY60D2ZgUGc86/7O6plXDjsXg==} 517 | dependencies: 518 | '@babel/helper-module-imports': 7.13.12 519 | '@babel/plugin-syntax-jsx': 7.12.13_@babel+core@7.14.2 520 | '@babel/types': 7.14.2 521 | transitivePeerDependencies: 522 | - '@babel/core' 523 | dev: true 524 | 525 | /babel-preset-solid/0.24.16_@babel+core@7.14.0: 526 | resolution: {integrity: sha512-NvKxmPStRTNNwK5mIZCfvB0GNZVqgUy6/nGVNVaISvkxwv8gZSSQNHMtdmCXINZ9I89aoISlMae4bkkHOXVxTg==} 527 | dependencies: 528 | babel-plugin-jsx-dom-expressions: 0.25.16_@babel+core@7.14.0 529 | transitivePeerDependencies: 530 | - '@babel/core' 531 | dev: true 532 | 533 | /babel-preset-solid/0.26.5_@babel+core@7.14.2: 534 | resolution: {integrity: sha512-SXMSmp3iL3FTbcy2QB4poHSbsPMrNSHOk8vIgQSMI/8UwxbxjjAG1iDDcqjsgWw6DqndxM6Z6nID9+94aT8NCQ==} 535 | dependencies: 536 | babel-plugin-jsx-dom-expressions: 0.26.3_@babel+core@7.14.2 537 | transitivePeerDependencies: 538 | - '@babel/core' 539 | dev: true 540 | 541 | /browserslist/4.16.6: 542 | resolution: {integrity: sha512-Wspk/PqO+4W9qp5iUTJsa1B/QrYn1keNCcEP5OvP7WBwT4KaDly0uONYmC6Xa3Z5IqnUgS0KcgLYu1l74x0ZXQ==} 543 | engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7} 544 | hasBin: true 545 | dependencies: 546 | caniuse-lite: 1.0.30001221 547 | colorette: 1.2.2 548 | electron-to-chromium: 1.3.726 549 | escalade: 3.1.1 550 | node-releases: 1.1.71 551 | dev: true 552 | 553 | /buffer-from/1.1.1: 554 | resolution: {integrity: sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==} 555 | dev: true 556 | 557 | /builtin-modules/3.2.0: 558 | resolution: {integrity: sha512-lGzLKcioL90C7wMczpkY0n/oART3MbBa8R9OFGE1rJxoVI86u4WAGfEk8Wjv10eKSyTHVGkSo3bvBylCEtk7LA==} 559 | engines: {node: '>=6'} 560 | dev: true 561 | 562 | /caniuse-lite/1.0.30001221: 563 | resolution: {integrity: sha512-b9TOZfND3uGSLjMOrLh8XxSQ41x8mX+9MLJYDM4AAHLfaZHttrLNPrScWjVnBITRZbY5sPpCt7X85n7VSLZ+/g==} 564 | dev: true 565 | 566 | /chalk/2.4.2: 567 | resolution: {integrity: sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==} 568 | engines: {node: '>=4'} 569 | dependencies: 570 | ansi-styles: 3.2.1 571 | escape-string-regexp: 1.0.5 572 | supports-color: 5.5.0 573 | dev: true 574 | 575 | /color-convert/1.9.3: 576 | resolution: {integrity: sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==} 577 | dependencies: 578 | color-name: 1.1.3 579 | dev: true 580 | 581 | /color-name/1.1.3: 582 | resolution: {integrity: sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=} 583 | dev: true 584 | 585 | /colorette/1.2.2: 586 | resolution: {integrity: sha512-MKGMzyfeuutC/ZJ1cba9NqcNpfeqMUcYmyF1ZFY6/Cn7CNSAKx6a+s48sqLqyAiZuaP2TcqMhoo+dlwFnVxT9w==} 587 | dev: true 588 | 589 | /commander/2.20.3: 590 | resolution: {integrity: sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==} 591 | dev: true 592 | 593 | /convert-source-map/1.7.0: 594 | resolution: {integrity: sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA==} 595 | dependencies: 596 | safe-buffer: 5.1.2 597 | dev: true 598 | 599 | /debug/4.3.1: 600 | resolution: {integrity: sha512-doEwdvm4PCeK4K3RQN2ZC2BYUBaxwLARCqZmMjtF8a51J2Rb0xpVloFRnCODwqjpwnAoao4pelN8l3RJdv3gRQ==} 601 | engines: {node: '>=6.0'} 602 | peerDependencies: 603 | supports-color: '*' 604 | peerDependenciesMeta: 605 | supports-color: 606 | optional: true 607 | dependencies: 608 | ms: 2.1.2 609 | dev: true 610 | 611 | /deepmerge/4.2.2: 612 | resolution: {integrity: sha512-FJ3UgI4gIl+PHZm53knsuSFpE+nESMr7M4v9QcgB7S63Kj/6WqMiFQJpBBYz1Pt+66bZpP3Q7Lye0Oo9MPKEdg==} 613 | engines: {node: '>=0.10.0'} 614 | dev: true 615 | 616 | /electron-to-chromium/1.3.726: 617 | resolution: {integrity: sha512-dw7WmrSu/JwtACiBzth8cuKf62NKL1xVJuNvyOg0jvruN/n4NLtGYoTzciQquCPNaS2eR+BT5GrxHbslfc/w1w==} 618 | dev: true 619 | 620 | /esbuild/0.11.21: 621 | resolution: {integrity: sha512-FqpYdJqiTeLDbj3vqxc/fG8UmHIEvQrDaUxSw1oJf4giLd/tnMDUUlXellCjOab7qGKQ5hUFD5eQgmO+tkZeow==} 622 | hasBin: true 623 | requiresBuild: true 624 | dev: true 625 | 626 | /esbuild/0.9.7: 627 | resolution: {integrity: sha512-VtUf6aQ89VTmMLKrWHYG50uByMF4JQlVysb8dmg6cOgW8JnFCipmz7p+HNBl+RR3LLCuBxFGVauAe2wfnF9bLg==} 628 | hasBin: true 629 | requiresBuild: true 630 | dev: true 631 | 632 | /escalade/3.1.1: 633 | resolution: {integrity: sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==} 634 | engines: {node: '>=6'} 635 | dev: true 636 | 637 | /escape-string-regexp/1.0.5: 638 | resolution: {integrity: sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=} 639 | engines: {node: '>=0.8.0'} 640 | dev: true 641 | 642 | /estree-walker/1.0.1: 643 | resolution: {integrity: sha512-1fMXF3YP4pZZVozF8j/ZLfvnR8NSIljt56UhbZ5PeeDmmGHpgpdwQt7ITlGvYaQukCvuBRMLEiKiYC+oeIg4cg==} 644 | dev: true 645 | 646 | /fsevents/2.3.2: 647 | resolution: {integrity: sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==} 648 | engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} 649 | os: [darwin] 650 | dev: true 651 | optional: true 652 | 653 | /function-bind/1.1.1: 654 | resolution: {integrity: sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==} 655 | dev: true 656 | 657 | /gensync/1.0.0-beta.2: 658 | resolution: {integrity: sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==} 659 | engines: {node: '>=6.9.0'} 660 | dev: true 661 | 662 | /globals/11.12.0: 663 | resolution: {integrity: sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==} 664 | engines: {node: '>=4'} 665 | dev: true 666 | 667 | /has-flag/3.0.0: 668 | resolution: {integrity: sha1-tdRU3CGZriJWmfNGfloH87lVuv0=} 669 | engines: {node: '>=4'} 670 | dev: true 671 | 672 | /has-flag/4.0.0: 673 | resolution: {integrity: sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==} 674 | engines: {node: '>=8'} 675 | dev: true 676 | 677 | /has/1.0.3: 678 | resolution: {integrity: sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==} 679 | engines: {node: '>= 0.4.0'} 680 | dependencies: 681 | function-bind: 1.1.1 682 | dev: true 683 | 684 | /is-core-module/2.3.0: 685 | resolution: {integrity: sha512-xSphU2KG9867tsYdLD4RWQ1VqdFl4HTO9Thf3I/3dLEfr0dbPTWKsuCKrgqMljg4nPE+Gq0VCnzT3gr0CyBmsw==} 686 | dependencies: 687 | has: 1.0.3 688 | dev: true 689 | 690 | /is-module/1.0.0: 691 | resolution: {integrity: sha1-Mlj7afeMFNW4FdZkM2tM/7ZEFZE=} 692 | dev: true 693 | 694 | /is-what/3.14.1: 695 | resolution: {integrity: sha512-sNxgpk9793nzSs7bA6JQJGeIuRBQhAaNGG77kzYQgMkrID+lS6SlK07K5LaptscDlSaIgH+GPFzf+d75FVxozA==} 696 | dev: true 697 | 698 | /jest-worker/26.6.2: 699 | resolution: {integrity: sha512-KWYVV1c4i+jbMpaBC+U++4Va0cp8OisU185o73T1vo99hqi7w8tSJfUXYswwqqrjzwxa6KpRK54WhPvwf5w6PQ==} 700 | engines: {node: '>= 10.13.0'} 701 | dependencies: 702 | '@types/node': 15.0.1 703 | merge-stream: 2.0.0 704 | supports-color: 7.2.0 705 | dev: true 706 | 707 | /js-tokens/4.0.0: 708 | resolution: {integrity: sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==} 709 | dev: true 710 | 711 | /jsesc/2.5.2: 712 | resolution: {integrity: sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==} 713 | engines: {node: '>=4'} 714 | hasBin: true 715 | dev: true 716 | 717 | /json5/2.2.0: 718 | resolution: {integrity: sha512-f+8cldu7X/y7RAJurMEJmdoKXGB/X550w2Nr3tTbezL6RwEE/iMcm+tZnXeoZtKuOq6ft8+CqzEkrIgx1fPoQA==} 719 | engines: {node: '>=6'} 720 | hasBin: true 721 | dependencies: 722 | minimist: 1.2.5 723 | dev: true 724 | 725 | /merge-anything/4.0.1: 726 | resolution: {integrity: sha512-KsFjBYc3juDoHz9Vzd5fte1nqp06H8SQ+yU344Dd0ZunwSgtltnC0kgKds8cbocJGyViLcBQuHkitbDXAqW+LQ==} 727 | dependencies: 728 | is-what: 3.14.1 729 | ts-toolbelt: 9.6.0 730 | dev: true 731 | 732 | /merge-stream/2.0.0: 733 | resolution: {integrity: sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==} 734 | dev: true 735 | 736 | /minimist/1.2.5: 737 | resolution: {integrity: sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==} 738 | dev: true 739 | 740 | /ms/2.1.2: 741 | resolution: {integrity: sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==} 742 | dev: true 743 | 744 | /nanoid/3.1.23: 745 | resolution: {integrity: sha512-FiB0kzdP0FFVGDKlRLEQ1BgDzU87dy5NnzjeW9YZNt+/c3+q82EQDUwniSAUxp/F0gFNI1ZhKU1FqYsMuqZVnw==} 746 | engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} 747 | hasBin: true 748 | dev: true 749 | 750 | /node-releases/1.1.71: 751 | resolution: {integrity: sha512-zR6HoT6LrLCRBwukmrVbHv0EpEQjksO6GmFcZQQuCAy139BEsoVKPYnf3jongYW83fAa1torLGYwxxky/p28sg==} 752 | dev: true 753 | 754 | /path-parse/1.0.6: 755 | resolution: {integrity: sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw==} 756 | dev: true 757 | 758 | /picomatch/2.2.3: 759 | resolution: {integrity: sha512-KpELjfwcCDUb9PeigTs2mBJzXUPzAuP2oPcA989He8Rte0+YUAjw1JVedDhuTKPkHjSYzMN3npC9luThGYEKdg==} 760 | engines: {node: '>=8.6'} 761 | dev: true 762 | 763 | /postcss/8.2.15: 764 | resolution: {integrity: sha512-2zO3b26eJD/8rb106Qu2o7Qgg52ND5HPjcyQiK2B98O388h43A448LCslC0dI2P97wCAQRJsFvwTRcXxTKds+Q==} 765 | engines: {node: ^10 || ^12 || >=14} 766 | dependencies: 767 | colorette: 1.2.2 768 | nanoid: 3.1.23 769 | source-map: 0.6.1 770 | dev: true 771 | 772 | /prettier/2.3.0: 773 | resolution: {integrity: sha512-kXtO4s0Lz/DW/IJ9QdWhAf7/NmPWQXkFr/r/WkR3vyI+0v8amTDxiaQSLzs8NBlytfLWX/7uQUMIW677yLKl4w==} 774 | engines: {node: '>=10.13.0'} 775 | hasBin: true 776 | dev: true 777 | 778 | /randombytes/2.1.0: 779 | resolution: {integrity: sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==} 780 | dependencies: 781 | safe-buffer: 5.2.1 782 | dev: true 783 | 784 | /resolve/1.20.0: 785 | resolution: {integrity: sha512-wENBPt4ySzg4ybFQW2TT1zMQucPK95HSh/nq2CFTZVOGut2+pQvSsgtda4d26YrYcr067wjbmzOG8byDPBX63A==} 786 | dependencies: 787 | is-core-module: 2.3.0 788 | path-parse: 1.0.6 789 | dev: true 790 | 791 | /rollup-plugin-terser/7.0.2_rollup@2.47.0: 792 | resolution: {integrity: sha512-w3iIaU4OxcF52UUXiZNsNeuXIMDvFrr+ZXK6bFZ0Q60qyVfq4uLptoS4bbq3paG3x216eQllFZX7zt6TIImguQ==} 793 | peerDependencies: 794 | rollup: ^2.0.0 795 | dependencies: 796 | '@babel/code-frame': 7.12.13 797 | jest-worker: 26.6.2 798 | rollup: 2.47.0 799 | serialize-javascript: 4.0.0 800 | terser: 5.7.0 801 | dev: true 802 | 803 | /rollup-preset-solid/0.3.0: 804 | resolution: {integrity: sha512-xlxfzpff5+r3nLwQFQqgjlG+a8VQBiXnQuw4rMviiip9E52s/K8YinkxdkEj1tXIuw6fA+YHTenlu71KdnqRWA==} 805 | dependencies: 806 | '@babel/core': 7.14.0 807 | '@babel/preset-typescript': 7.13.0_@babel+core@7.14.0 808 | '@rollup/plugin-babel': 5.3.0_@babel+core@7.14.0+rollup@2.47.0 809 | '@rollup/plugin-node-resolve': 11.2.1_rollup@2.47.0 810 | babel-preset-solid: 0.24.16_@babel+core@7.14.0 811 | colorette: 1.2.2 812 | esbuild: 0.9.7 813 | merge-anything: 4.0.1 814 | rollup: 2.47.0 815 | rollup-plugin-terser: 7.0.2_rollup@2.47.0 816 | typescript: 4.2.4 817 | transitivePeerDependencies: 818 | - '@types/babel__core' 819 | - supports-color 820 | dev: true 821 | 822 | /rollup/2.47.0: 823 | resolution: {integrity: sha512-rqBjgq9hQfW0vRmz+0S062ORRNJXvwRpzxhFXORvar/maZqY6za3rgQ/p1Glg+j1hnc1GtYyQCPiAei95uTElg==} 824 | engines: {node: '>=10.0.0'} 825 | hasBin: true 826 | optionalDependencies: 827 | fsevents: 2.3.2 828 | dev: true 829 | 830 | /safe-buffer/5.1.2: 831 | resolution: {integrity: sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==} 832 | dev: true 833 | 834 | /safe-buffer/5.2.1: 835 | resolution: {integrity: sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==} 836 | dev: true 837 | 838 | /semver/6.3.0: 839 | resolution: {integrity: sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==} 840 | hasBin: true 841 | dev: true 842 | 843 | /serialize-javascript/4.0.0: 844 | resolution: {integrity: sha512-GaNA54380uFefWghODBWEGisLZFj00nS5ACs6yHa9nLqlLpVLO8ChDGeKRjZnV4Nh4n0Qi7nhYZD/9fCPzEqkw==} 845 | dependencies: 846 | randombytes: 2.1.0 847 | dev: true 848 | 849 | /solid-js/0.26.5: 850 | resolution: {integrity: sha512-cMjxcVoyRBgnfSpwYxXPM5WF800guR+x/01RDBFQjAAkqU7X28GbRkTNKcyQ1KHcFOnzEsG18J+JJ9/PvqyNmw==} 851 | 852 | /solid-refresh/0.1.2_solid-js@0.26.5: 853 | resolution: {integrity: sha512-irpGTZcn9xtzTQZhHslIEB4D1zYpWizT6GZ15GXyQE/gFBn6bKo53umQGmhq3NqRFqPXXavFDhiEQnyC08gzNg==} 854 | peerDependencies: 855 | solid-js: '*' 856 | dependencies: 857 | solid-js: 0.26.5 858 | dev: true 859 | 860 | /source-map-support/0.5.19: 861 | resolution: {integrity: sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw==} 862 | dependencies: 863 | buffer-from: 1.1.1 864 | source-map: 0.6.1 865 | dev: true 866 | 867 | /source-map/0.5.7: 868 | resolution: {integrity: sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=} 869 | engines: {node: '>=0.10.0'} 870 | dev: true 871 | 872 | /source-map/0.6.1: 873 | resolution: {integrity: sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==} 874 | engines: {node: '>=0.10.0'} 875 | dev: true 876 | 877 | /source-map/0.7.3: 878 | resolution: {integrity: sha512-CkCj6giN3S+n9qrYiBTX5gystlENnRW5jZeNLHpe6aue+SrHcG5VYwujhW9s4dY31mEGsxBDrHR6oI69fTXsaQ==} 879 | engines: {node: '>= 8'} 880 | dev: true 881 | 882 | /supports-color/5.5.0: 883 | resolution: {integrity: sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==} 884 | engines: {node: '>=4'} 885 | dependencies: 886 | has-flag: 3.0.0 887 | dev: true 888 | 889 | /supports-color/7.2.0: 890 | resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==} 891 | engines: {node: '>=8'} 892 | dependencies: 893 | has-flag: 4.0.0 894 | dev: true 895 | 896 | /terser/5.7.0: 897 | resolution: {integrity: sha512-HP5/9hp2UaZt5fYkuhNBR8YyRcT8juw8+uFbAme53iN9hblvKnLUTKkmwJG6ocWpIKf8UK4DoeWG4ty0J6S6/g==} 898 | engines: {node: '>=10'} 899 | hasBin: true 900 | dependencies: 901 | commander: 2.20.3 902 | source-map: 0.7.3 903 | source-map-support: 0.5.19 904 | dev: true 905 | 906 | /to-fast-properties/2.0.0: 907 | resolution: {integrity: sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4=} 908 | engines: {node: '>=4'} 909 | dev: true 910 | 911 | /ts-toolbelt/9.6.0: 912 | resolution: {integrity: sha512-nsZd8ZeNUzukXPlJmTBwUAuABDe/9qtVDelJeT/qW0ow3ZS3BsQJtNkan1802aM9Uf68/Y8ljw86Hu0h5IUW3w==} 913 | dev: true 914 | 915 | /typescript/4.2.4: 916 | resolution: {integrity: sha512-V+evlYHZnQkaz8TRBuxTA92yZBPotr5H+WhQ7bD3hZUndx5tGOa1fuCgeSjxAzM1RiN5IzvadIXTVefuuwZCRg==} 917 | engines: {node: '>=4.2.0'} 918 | hasBin: true 919 | dev: true 920 | 921 | /vite-plugin-solid/1.8.0: 922 | resolution: {integrity: sha512-LdgrWCBdclR1Mim3pdZNf57IcmUh8KU/kdWgj3uDQKPMywmvS3V5DjhZHxeIpTV1ePLwkyZSmBzQkqTP1EoO8g==} 923 | dependencies: 924 | '@babel/core': 7.14.2 925 | '@babel/preset-typescript': 7.13.0_@babel+core@7.14.2 926 | babel-preset-solid: 0.26.5_@babel+core@7.14.2 927 | merge-anything: 4.0.1 928 | solid-js: 0.26.5 929 | solid-refresh: 0.1.2_solid-js@0.26.5 930 | vite: 2.3.2 931 | transitivePeerDependencies: 932 | - supports-color 933 | dev: true 934 | 935 | /vite/2.3.2: 936 | resolution: {integrity: sha512-QhLdOompDrfkyryCNTts9HE+eJhvhN9ibKNJ5Q8DpQai+6nOsuIlaveZNg67e1O/2QaWqXeBo82eHnAs1De2bQ==} 937 | engines: {node: '>=12.0.0'} 938 | hasBin: true 939 | dependencies: 940 | esbuild: 0.11.21 941 | postcss: 8.2.15 942 | resolve: 1.20.0 943 | rollup: 2.47.0 944 | optionalDependencies: 945 | fsevents: 2.3.2 946 | dev: true 947 | -------------------------------------------------------------------------------- /rollup.config.js: -------------------------------------------------------------------------------- 1 | import defineConfig from 'rollup-preset-solid'; 2 | 3 | export default defineConfig({ 4 | input: 'src/solid-repl.tsx', 5 | external: ['@amoutonbrady/lz-string'], 6 | printInstructions: true, 7 | }); 8 | -------------------------------------------------------------------------------- /src/solid-repl.tsx: -------------------------------------------------------------------------------- 1 | import { Show } from 'solid-js/web'; 2 | import { JSX, createMemo, splitProps } from 'solid-js'; 3 | import { compressToURL } from '@amoutonbrady/lz-string'; 4 | 5 | function uid() { 6 | const [ts, rand] = [Date.now(), Math.random()].map((value) => 7 | value.toString(36), 8 | ); 9 | 10 | return (ts + rand).replace(/\./g, ''); 11 | } 12 | 13 | function childrensToArray(children: unknown | unknown[]): T[] { 14 | return [...(Array.isArray(children) ? children : [children])]; 15 | } 16 | 17 | function formatCode(code: string) { 18 | const lines = code.split('\n'); 19 | 20 | let mindent: number | null = null; 21 | let result = code.replace(/\\\n[ \t]*/g, '').replace(/\\`/g, '`'); 22 | 23 | for (const line of lines) { 24 | const m = line.match(/^(\s+)\S+/); 25 | 26 | if (!m) continue; 27 | const indent = m[1].length; 28 | mindent = mindent ? Math.min(mindent, indent) : indent; 29 | } 30 | 31 | if (mindent !== null) { 32 | result = lines 33 | .map((line) => (line[0] === ' ' ? line.slice(mindent) : line)) 34 | .join('\n'); 35 | } 36 | 37 | return result.trim().replace(/\\n/g, '\n'); 38 | } 39 | 40 | export const ReplTab = (props: { 41 | name: string; 42 | children?: unknown | unknown[]; 43 | }) => { 44 | const id = uid(); 45 | 46 | return createMemo(() => { 47 | const source = childrensToArray(props.children).join(''); 48 | 49 | return { 50 | id, 51 | name: props.name, 52 | source: formatCode(source), 53 | type: 'tsx', 54 | } as unknown as JSX.Element; 55 | }); 56 | }; 57 | 58 | export const Repl = (props: ReplOptions) => { 59 | const [internal, external] = splitProps(props, [ 60 | 'data', 61 | 'height', 62 | 'baseUrl', 63 | 'children', 64 | 'isInteractive', 65 | 'withHeader', 66 | 'edtiableTabs', 67 | 'withActionBar', 68 | 'layout', 69 | ]); 70 | 71 | const tabs = createMemo(() => { 72 | if (!internal.children) return []; 73 | return childrensToArray<() => Tab>(internal.children).map((tab) => tab()); 74 | }); 75 | 76 | const src = createMemo(() => { 77 | const url = new URL(internal.baseUrl || 'https://playground.solidjs.com'); 78 | 79 | if (!internal.withHeader) url.searchParams.set('noHeader', 'true'); 80 | if (!internal.isInteractive) url.searchParams.set('noInteractive', 'true'); 81 | if (internal.data) url.searchParams.set('data', internal.data); 82 | if (!internal.edtiableTabs) url.searchParams.set('noEditableTabs', 'true') 83 | if (!internal.withActionBar) url.searchParams.set('noActionBar', 'true') 84 | if (internal.layout === 'vertical') url.searchParams.set('isHorizontal', 'true') 85 | 86 | if (tabs().length) { 87 | url.hash = compressToURL(JSON.stringify(tabs())); 88 | } 89 | 90 | return url.toString(); 91 | }); 92 | 93 | return ( 94 | The REPL needs to have at least one tab

} 97 | > 98 |