{"ast":null,"code":"import { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nimport axios from 'axios';\nimport React from 'react';\nimport BuildHeader from '../../components/header.js';\nimport TableBuilder from '../../components/tablefilter.js';\n\nfunction teamHistory({\n  fulldataset\n}) {\n  return /*#__PURE__*/_jsxs(\"div\", {\n    children: [/*#__PURE__*/_jsx(BuildHeader, {\n      headerData: fulldataset.headerdata\n    }), /*#__PURE__*/_jsx(\"div\", {\n      className: \"container mx-auto\",\n      children: /*#__PURE__*/_jsx(TableBuilder, {\n        props: fulldataset.dataset,\n        baseURL: fulldataset.dataset.baseURL\n      })\n    })]\n  });\n}\n\nexport default teamHistory;\nexport async function getServerSideProps(context) {\n  const urlData = context.resolvedUrl.split('?')[1];\n  const res = await axios.get('https://goallinestats.com/phpAPI/playerstatsJSON.php?' + urlData);\n  const dataset = res.data;\n  dataset['baseURL'] = 'https://goallinestats.com/phpAPI/playerstatsJSON.php?' + urlData;\n  const index = await axios.get('https://goallinestats.com/phpAPI/headerJSON.php?' + urlData);\n  const indexData = index.data;\n  const fulldataset = {\n    headerdata: indexData,\n    dataset: dataset\n  };\n  return {\n    props: {\n      fulldataset\n    }\n  };\n}","map":null,"metadata":{},"sourceType":"module"}