Frontend/25_01_07/mai/node_modules/.cache/babel-loader/7d77a43ca078a69012c29ef4e311b7ca029d42a6944102a8a37e45e9009965cf.json

1 line
4.7 KiB
JSON
Raw Permalink Normal View History

2025-01-28 10:38:27 +00:00
{"ast":null,"code":"var _jsxFileName = \"C:\\\\Users\\\\szabomarton\\\\Desktop\\\\Frontend\\\\Frontend\\\\25_01_07\\\\mai\\\\src\\\\Szamlalo.js\",\n _s = $RefreshSig$();\nimport React from \"react\";\nimport { useState, useEffect } from \"react\";\nimport { jsxDEV as _jsxDEV } from \"react/jsx-dev-runtime\";\nfunction Szamlalo() {\n _s();\n const [counter, setCounter] = useState(0);\n const [message, setMessage] = useState('');\n const [counter2, setCounter2] = useState(0);\n useEffect(() => {\n setMessage(`A számláló értéke: ${counter}`);\n console.log(`useEffect lefutott, mert a counter értéke ${counter}`);\n }, [counter, setCounter2]);\n return /*#__PURE__*/_jsxDEV(\"div\", {\n children: [/*#__PURE__*/_jsxDEV(\"h1\", {\n children: \"React useEffect F\\xFCgg\\u0151s\\xE9g p\\xE9lda\"\n }, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 16,\n columnNumber: 13\n }, this), /*#__PURE__*/_jsxDEV(\"p\", {\n children: message\n }, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 19,\n columnNumber: 13\n }, this), /*#__PURE__*/_jsxDEV(\"button\", {\n onClick: () => setCounter(counter + 1),\n children: \"N\\xF6vel\\xE9s\"\n }, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 20,\n columnNumber: 13\n }, this), /*#__PURE__*/_jsxDEV(\"button\", {\n onClick: () => setCounter(counter - 1),\n children: \"Cs\\xF6kkent\\xE9s\"\n }, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 21,\n columnNumber: 13\n }, this), /*#__PURE__*/_jsxDEV(\"button\", {\n onClick: () => setCounter(0),\n children: \"Null\\xE1z\\xE1s\"\n }, void 0, false, {\n fileName: _jsxFileName,\n lineNumber: 22,\n columnNumber: 13\n }, this)]\n }, void 0, true, {\n fileName: _jsxFileName,\n lineNumber: 15,\n columnNumber: 9\n }, this);\n}\n_s(Szamlalo, \"DHX4BODyQsijlUoZTh6+nTUwBu4=\");\n_c = Szamlalo;\nexport default Szamlalo;\nvar _c;\n$RefreshReg$(_c, \"Szamlalo\");","map":{"version":3,"names":["React","useState","useEffect","jsxDEV","_jsxDEV","Szamlalo","_s","counter","setCounter","message","setMessage","counter2","setCounter2","console","log","children","fileName","_jsxFileName","lineNumber","columnNumber","onClick","_c","$RefreshReg$"],"sources":["C:/Users/szabomarton/Desktop/Frontend/Frontend/25_01_07/mai/src/Szamlalo.js"],"sourcesContent":["import React from \"react\";\r\nimport { useState, useEffect } from \"react\";\r\n\r\nfunction Szamlalo() {\r\n const [counter, setCounter] = useState(0);\r\n const [message, setMessage] = useState('');\r\n const [counter2, setCounter2] = useState(0);\r\n\r\n useEffect(() => {\r\n setMessage(`A számláló értéke: ${counter}`);\r\n console.log(`useEffect lefutott, mert a counter értéke ${counter}`);\r\n }, [counter, setCounter2]);\r\n\r\n return (\r\n <div>\r\n <h1>\r\n React useEffect Függőség példa\r\n </h1>\r\n <p>{message}</p>\r\n <button onClick={() => setCounter(counter + 1)}>Növelés</button>\r\n <button onClick={() => setCounter(counter - 1)}>Csökkentés</button>\r\n <button onClick={() => setCounter(0)}>Nullázás</button>\r\n </div>\r\n )\r\n}\r\n\r\nexport default Szamlalo;"],"mappings":";;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,QAAQ,EAAEC,SAAS,QAAQ,OAAO;AAAC,SAAAC,MAAA,IAAAC,OAAA;AAE5C,SAASC,QAAQA,CAAA,EAAG;EAAAC,EAAA;EAChB,MAAM,CAACC,OAAO,EAAEC,UAAU,CAAC,GAAGP,QAAQ,CAAC,CAAC,CAAC;EACzC,MAAM,CAACQ,OAAO,EAAEC,UAAU,CAAC,GAAGT,QAAQ,CAAC,EAAE,CAAC;EAC1C,MAAM,CAACU,QAAQ,EAAEC,WAAW,CAAC,GAAGX,QAAQ,CAAC,CAAC,CAAC;EAE3CC,SAAS,CAAC,MAAM;IACZQ,UAAU,CAAC,sBAAsBH,OAAO,EAAE,CAAC;IAC3CM,OAAO,CAACC,GAAG,CAAC,6CAA6CP,OAAO,EAAE,CAAC;EACvE,CAAC,EAAE,CAACA,OAAO,EAAEK,WAAW,CAAC,CAAC;EAE1B,oBACIR,OAAA;IAAAW,QAAA,gBACIX,OAAA;MAAAW,QAAA,EAAI;IAEJ;MAAAC,QAAA,EAAAC,YAAA;MAAAC,UAAA;MAAAC,YAAA;IAAA,OAAI,CAAC,eACLf,OAAA;MAAAW,QAAA,EAAIN;IAAO;MAAAO,QAAA,EAAAC,YAAA;MAAAC,UAAA;MAAAC,YAAA;IAAA,OAAI,CA