{"dist":{"shasum":"00188a24a018bc510f5d66765e0f84f901c096e7","tarball":"https://registry.npmjs.org/jsx2mp-runtime/-/jsx2mp-runtime-0.4.26-0.tgz","fileCount":7,"integrity":"sha512-nDm4IcYy4nJywf7iHcwakQ/Hy7pzG2wE6rh738PRX42aXMgiut7vGgoba1eLRS/mXoVEaGOGdwaGzA4DOWng3A==","signatures":[{"sig":"MEYCIQDvPpcn3uqWD35AZ1yLVXNG8z9FnJ4hX5aExzh19iE9QQIhAPBQRMCGxiDFRMUYoqLdVpaPRQ6R9V5hGTw0Kwjvt5tb","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":227943,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJiAOAxCRA9TVsSAnZWagAAxg4P/ju6BgtOFuIz6M1qyWRF\nxo1iJwhoy8LrrTHJ8lN+wA6C9Win5mRmZkZSsO6c9kaXpqN4whDjHckb2Vpl\nSOVKut1LlBWkolFrNzWsCQ3CqUjom/+5YkT6S6q8eizNDQ172adm0lDdXaKa\nWIJ6Ul9Rp41HR5ULUwzN3gd458ksxjSxnSwWwB/r+7JFIXokJe4wAVxkELrf\n0yZZfHG3COdzTInEix4/Jhd8t42GzVMdPlQtaXmrmu8w9efvlbHCUafzPo+F\n7lrsFcxVgVZcnS2k+hWDMlSe+jHfA29agWs4cfNvIx2XOfO320zizexof2zZ\nryI7h4ltJRPc8ZOTnXe+9tIox3+8/Utxu8vJ+kch4Ba2pOxAbjjRg3wjjbZL\nzOigv0PzgJNX4UY1LHj/2l6rLrBE+Y7ndmRJZupWBldWpsJPQ/spjXSZVpNq\nv2IKiwxmqVtq1kM7S4O8FZjtwpN0X+8jdGfa4M8N5xSxOz6insttz06aaZLw\nZSao4v3rmqGQo/BtknAC08WTk3kBB0NLn598NEBPFBl6qgOx1uOIBSOSPrT8\n5N93pqu9CsySzWaNjGNpXxU6ftxYrAdfE8Zr+72878g01mzAKPsE2i62T7gB\nRoSe4sb1FZMN9qiEYXnVjCLS4MBvER+nYpl7MZsz30QgdbPMkMFbzQgFGTER\nQX3I\r\n=l+Za\r\n-----END PGP SIGNATURE-----\r\n"},"jest":{"collectCoverage":true},"name":"jsx2mp-runtime","author":{"name":"Rax Team"},"readme":"# jsx2mp-runtime\n\nProvide runtime support for rax style miniapp.\n\n- createComponent\n   ```js\n   const __class_def__ = class {\n     state = {\n       name: 'Rax'\n     };\n   \n     handleTap() {\n       this.setState({\n         name: 'MiniApp'\n       });\n     }\n   };\n   \n   const config = createComponent(__class_def__, 'class');\n\n  Component(config);\n  ```\n- (state) useState(defaultValue, key)\n  ```js\n  const __fn_def__ = function Header(props) {\n    const [name, setName] = useState('World', 'name');\n    const [count, setCount] = useState(0, 'count');\n  \n    return {\n      handleClick() {\n        setName('Rax');\n        setCount(count + 1);\n      }\n    }\n  };\n  \n  const config = createComponent(__fn_def__, 'function');\n  Component(config);\n  ```\n- (void) useEffect(callback)\n  ```js\n  const __fn_def__ = function Header(props) {\n    const [name, setName] = useState('World', 'name');\n    useEffect(() => {\n      console.log('didMount');\n  \n      return function unmount() {\n        console.log('unmount');\n      };\n    }, []);\n  \n    return {\n      handleClick: () => {\n        setName('Rax');\n      },\n    };\n  };\n  \n  const config = createComponent(__fn_def__, 'function');\n  Component(config);\n  ```\n","scripts":{"test":"jest --coverage --testPathIgnorePatterns=__modules__","build":"cross-env NODE_ENV=production rollup -c rollup.config.js","prepublishOnly":"npm run build"},"_npmUser":{"name":"rax-publisher","email":"rax-public@alibaba-inc.com"},"_npmVersion":"6.14.12","description":"Runtime for jsx2mp.","directories":{},"maintainers":[{"name":"zeroling","email":"wssgcg1213@qq.com"},{"name":"likai757","email":"likai757@gmail.com"},{"name":"solojiang","email":"feifeishen1996@gmail.com"},{"name":"chriscindy","email":"yxy0919@foxmail.com"},{"name":"rax-publisher","email":"rax-public@alibaba-inc.com"}],"miniprogram":".","_nodeVersion":"14.16.1","_hasShrinkwrap":false,"readmeFilename":"README.md","devDependencies":{"jest":"^27.4.7","rollup":"^1.13.1","cross-env":"^5.2.0","@babel/core":"^7.4.5","@babel/types":"^7.8.3","universal-env":"^3.0.0","@babel/preset-env":"^7.4.5","rollup-plugin-babel":"^4.3.2","rollup-plugin-cleanup":"^3.1.1","rollup-plugin-replace":"^2.2.0","rollup-plugin-filesize":"^6.1.0","@babel/plugin-proposal-class-properties":"^7.5.5","@babel/plugin-transform-modules-commonjs":"^7.16.8"},"_npmOperationalInternal":{"tmp":"tmp/jsx2mp-runtime_0.4.26-0_1644224561549_0.0053098622044254196","host":"s3://npm-registry-packages"},"_id":"jsx2mp-runtime@0.4.26-0","version":"0.4.26-0"}