UNPKG

3.53 kBPlain TextView Raw
1{"code":"function defineName$__(cls,name){\n\tObject.defineProperty(cls,\"name\",{value:name,configurable:true});\n};\nimport {use_events as imba_use_events, Component as imba_Component, commit as imba_commit, createComponent as imba_createComponent, createElement as imba_createElement, defineTag as imba_defineTag} from 'imba';\n(imba_use_events());\nconst $__init__$ = Symbol.for('#__init__'), $__patch__$ = Symbol.for('#__patch__'), $beforeReconcile$ = Symbol.for('#beforeReconcile'), $placeChild$ = Symbol.for('#placeChild'), $afterVisit$ = Symbol.for('#afterVisit'), $appendChild$ = Symbol.for('#appendChild'), $afterReconcile$ = Symbol.for('#afterReconcile');\nvar $6 = Symbol(), $9 = Symbol(), $13 = Symbol(), $14 = Symbol(), $16 = Symbol();\n\n/*body*/\nimport './counter';\nimport './shared';\n\nexport default class App extends imba_Component {\n\t[$__patch__$]($$ = {},fields = true){\n\t\tvar $1;\n\t\t($1 = $$.count) !== undefined && (this.count = $1);\n\t\t\n\t}\n\t[$__init__$]($$ = null,deep = true,fields = true){\n\t\tvar $2;\n\t\tsuper[$__init__$](...arguments);\n\t\tthis.count = ($$ && ($2 = $$.count) !== undefined) ? ($2) : 0;\n\t\t\n\t}\n\tmount(){\n\t\t\n\t\treturn this.count++;\n\t}\n\t\n\thydrate(){\n\t\t\n\t\tthis.innerHTML = '';\n\t\tthis.schedule();\n\t\treturn imba_commit();\n\t}\n\trender(){\n\t\tvar self = this, $3, $4, $5, $7 = this._ns_ || '', $8, $10, $11, $12, $15, $17, $18;\n\t\t\n\t\t$3=this;\n\t\t$3[$beforeReconcile$]();\n\t\t($4=$5=1,$3[$6] === 1) || ($4=$5=0,$3[$6]=1);\n\t\t($10=$11=1,$8=$3[$9]) || ($10=$11=0,$3[$9]=$8=imba_createElement('button',$3,`buteef-ag ${$7}`,null));\n\t\t$10 || ($8.on$(`click`,{log: [\"st\"],$_: [function(e,$$) {\n\t\t\treturn self.count++;\n\t\t}]},this));\n\t\t$10 || $8[$placeChild$](\"Hello \");\n\t\t($12=this.count,($12===$3[$14]&&$10) || ($3[$13] = $8[$placeChild$]($3[$14]=$12,0,$3[$13])));\n\t\t$10 || $8[$placeChild$](\" times hello\");\n\t\t;\n\t\t($17=$18=1,$15=$3[$16]) || ($17=$18=0,$3[$16]=$15=imba_createComponent('my-counter',$3,`${$7}`,null));\n\t\t$17 || !$15.setup || $15.setup($18);\n\t\t$15[$afterVisit$]($18);\n\t\t$17 || $3[$appendChild$]($15);\n\t\t;\n\t\t$3[$afterReconcile$]($5);\n\t\treturn $3;\n\t}\n\tstatic {\n\t\tdefineName$__(this,'App');}\n}; imba_defineTag('app-buteef-ai',App,{});\n\n/*__css_import__*/import \"/Users/abdellah/workspace/scrimba/imba/temp/serve/vite-middleware/src/App.imba?imba&type=style&lang.css\";\n","map":{"version":3,"file":"App.js","sourceRoot":"","sources":["/Users/abdellah/workspace/scrimba/imba/temp/serve/vite-middleware/src/App.imba"],"sourcesContent":["import './counter'\nimport './shared'\n\nglobal css body bgc:cool8\nglobal css @root $about:1\n\nexport default tag App\n\tcount = 0\n\tdef mount\n\t\tcount++\n\n\tdef hydrate\n\t\tinnerHTML = ''\n\t\tschedule!\n\t\timba.commit!\n\tdef render\n\t\t<self>\n\t\t\t<button[c:green bg:yellow4] @click.log(\"st\")=(count++)> \"Hello {count} times hello\"\n\t\t\t<my-counter>\n"],"names":[],"mappings":";;;;;;;;;AAAA,MAAM,CAAC,WAAW;AAClB,MAAM,CAAC,UAAU;;AAKjB,MAAM,CAAC,OAAO,CAAC,KAAG,CAAC,GAAG,yBAAA;qCANtB;;WAOC,KAAK,CAAA,wBAAL,KAAK;;EAPN;kDAAA;;;OAOC,KAAK,mBAAL,KAAK,CAAA,qBAAA,IAAG,CAAC;;EAPV;CAQK,KAAK,EAAA;;EACR,OAAA,KAAA,KAAK,EAAE;EAAA;;CAEJ,OAAO,EAAA;;EACV,KAAA,SAAS,GAAG,EAAE;EACd,KAAA,QAAQ,EAAC;EACT,OAAA,WAAW,EAAC;EAAA;CACT,MAAM,EAAA;;;;;;gDAEP,sDAAM;+BAAgC,CAAA,IAAI,CAAA,qBAjB9C;GAiBiD,OAAA,KAAA,KAAK,EAAE;GAjBxD;;OAiBmE,KAAA,KAAK;;;oDACpE,kDAAU;;;;;;;EAAC;;;AAAA,yCAAA;AACf;"},"dependencies":[],"meta":{"vite":{"lang":"js"}}}
\No newline at end of file