@maka/maka-cli 4.5.2 → 4.5.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (109) hide show
  1. package/bundle/obf/package.json +1 -1
  2. package/bundle/obf/src/command.js +1 -1
  3. package/bundle/obf/src/commands/_index.js +1 -1
  4. package/bundle/obf/src/commands/aws/_index.js +1 -1
  5. package/bundle/obf/src/commands/aws/aws.command.js +1 -1
  6. package/bundle/obf/src/commands/aws/ci.sub.cmd.js +1 -1
  7. package/bundle/obf/src/commands/aws/ckp.sub.cmd.js +1 -1
  8. package/bundle/obf/src/commands/aws/csg.sub.cmd.js +1 -1
  9. package/bundle/obf/src/commands/aws/di.sub.cmd.js +1 -1
  10. package/bundle/obf/src/commands/aws/dkp.sub.cmd.js +1 -1
  11. package/bundle/obf/src/commands/aws/dsg.sub.cmd.js +1 -1
  12. package/bundle/obf/src/commands/aws/rbi.sub.cmd.js +1 -1
  13. package/bundle/obf/src/commands/aws/rkp.sub.cmd.js +1 -1
  14. package/bundle/obf/src/commands/aws/sth.sub.cmd.js +1 -1
  15. package/bundle/obf/src/commands/aws/ti.sub.cmd.js +1 -1
  16. package/bundle/obf/src/commands/build/_index.js +1 -1
  17. package/bundle/obf/src/commands/build/build.js +1 -1
  18. package/bundle/obf/src/commands/build/docker.sub.cmd.js +1 -1
  19. package/bundle/obf/src/commands/create.js +1 -1
  20. package/bundle/obf/src/commands/debug.js +1 -1
  21. package/bundle/obf/src/commands/deploy.js +1 -1
  22. package/bundle/obf/src/commands/game/_index.js +1 -1
  23. package/bundle/obf/src/commands/game/battleship.sub.cmd.js +1 -1
  24. package/bundle/obf/src/commands/game/play.command.js +1 -1
  25. package/bundle/obf/src/commands/game/pong.sub.cmd.js +1 -1
  26. package/bundle/obf/src/commands/game/snake.sub.cmd.js +1 -1
  27. package/bundle/obf/src/commands/game/tetris.sub.cmd.js +1 -1
  28. package/bundle/obf/src/commands/generate.js +1 -1
  29. package/bundle/obf/src/commands/get/_index.js +1 -1
  30. package/bundle/obf/src/commands/get/get.command.js +1 -1
  31. package/bundle/obf/src/commands/get/global.sub.cmd.js +1 -1
  32. package/bundle/obf/src/commands/get/local.sub.cmd.js +1 -1
  33. package/bundle/obf/src/commands/get/whoami.sub.cmd.js +1 -1
  34. package/bundle/obf/src/commands/help.js +1 -1
  35. package/bundle/obf/src/commands/install.js +1 -1
  36. package/bundle/obf/src/commands/jsdoc.js +1 -1
  37. package/bundle/obf/src/commands/lint.js +1 -1
  38. package/bundle/obf/src/commands/login.js +1 -1
  39. package/bundle/obf/src/commands/logout.js +1 -1
  40. package/bundle/obf/src/commands/logs.js +1 -1
  41. package/bundle/obf/src/commands/maka.cmd.js +1 -1
  42. package/bundle/obf/src/commands/murder.js +1 -1
  43. package/bundle/obf/src/commands/proxy.js +1 -1
  44. package/bundle/obf/src/commands/reconfig.js +1 -1
  45. package/bundle/obf/src/commands/run/_index.js +1 -1
  46. package/bundle/obf/src/commands/run/docker.sub.cmd.js +1 -1
  47. package/bundle/obf/src/commands/run/run.command.js +1 -1
  48. package/bundle/obf/src/commands/set/_index.js +1 -1
  49. package/bundle/obf/src/commands/set/global.sub.cmd.js +1 -1
  50. package/bundle/obf/src/commands/set/local.sub.cmd.js +1 -1
  51. package/bundle/obf/src/commands/set/set.command.js +1 -1
  52. package/bundle/obf/src/commands/ssh.js +1 -1
  53. package/bundle/obf/src/commands/ssl.js +1 -1
  54. package/bundle/obf/src/commands/test.js +1 -1
  55. package/bundle/obf/src/commands/version.js +1 -1
  56. package/bundle/obf/src/error.js +1 -1
  57. package/bundle/obf/src/generator.js +1 -1
  58. package/bundle/obf/src/generators/_index.js +1 -1
  59. package/bundle/obf/src/generators/api.js +1 -1
  60. package/bundle/obf/src/generators/collection.js +1 -1
  61. package/bundle/obf/src/generators/component.js +1 -1
  62. package/bundle/obf/src/generators/config.js +1 -1
  63. package/bundle/obf/src/generators/dbc.js +1 -1
  64. package/bundle/obf/src/generators/dockerfile.js +1 -1
  65. package/bundle/obf/src/generators/hook.js +1 -1
  66. package/bundle/obf/src/generators/kit.js +1 -1
  67. package/bundle/obf/src/generators/layout.js +1 -1
  68. package/bundle/obf/src/generators/maka.gen.js +1 -1
  69. package/bundle/obf/src/generators/methods.js +1 -1
  70. package/bundle/obf/src/generators/package.js +1 -1
  71. package/bundle/obf/src/generators/page.js +1 -1
  72. package/bundle/obf/src/generators/publish.js +1 -1
  73. package/bundle/obf/src/generators/route.js +1 -1
  74. package/bundle/obf/src/generators/service.js +1 -1
  75. package/bundle/obf/src/generators/services/_index.js +1 -1
  76. package/bundle/obf/src/generators/services/openssl.js +1 -1
  77. package/bundle/obf/src/generators/services/translation.js +1 -1
  78. package/bundle/obf/src/maka.js +1 -1
  79. package/bundle/obf/src/templates/meteor/app/imports/startup/client/index.js.jsx +20 -6
  80. package/bundle/obf/src/templates/meteor/app/imports/startup/client/index.js.tsx +21 -7
  81. package/bundle/obf/src/templates/meteor/app/imports/startup/lib/index.js.jsx +10 -0
  82. package/bundle/obf/src/templates/meteor/app/imports/startup/lib/index.js.tsx +10 -0
  83. package/bundle/obf/src/templates/meteor/app/imports/startup/server/index.js.jsx +25 -14
  84. package/bundle/obf/src/templates/meteor/app/imports/startup/server/index.js.tsx +25 -13
  85. package/bundle/obf/src/templates/meteor/template/template.js.jsx +1 -1
  86. package/bundle/obf/src/templates/meteor/template/template.js.tsx +1 -1
  87. package/bundle/obf/src/templates/react/component/component.js.jsx +2 -6
  88. package/bundle/obf/src/templates/react/component/component.js.tsx +2 -6
  89. package/bundle/obf/src/templates/react/hook/hook.js.jsx +1 -5
  90. package/bundle/obf/src/templates/react/hook/hook.js.tsx +1 -5
  91. package/bundle/obf/src/tool.js +1 -1
  92. package/bundle/obf/src/tools/actions/actions.class.js +1 -1
  93. package/bundle/obf/src/tools/actions/actions.test.js +1 -1
  94. package/bundle/obf/src/tools/aws/aws.class.js +1 -1
  95. package/bundle/obf/src/tools/aws/aws.interfaces.js +1 -1
  96. package/bundle/obf/src/tools/docker/docker.class.js +1 -1
  97. package/bundle/obf/src/tools/docker/docker.interfaces.js +1 -1
  98. package/bundle/obf/src/tools/fsi/fsi.class.js +1 -1
  99. package/bundle/obf/src/tools/fsi/fsi.interfaces.js +1 -1
  100. package/bundle/obf/src/tools/https/https.class.js +1 -1
  101. package/bundle/obf/src/tools/https/https.interface.js +1 -1
  102. package/bundle/obf/src/tools/log/log.class.js +1 -1
  103. package/bundle/obf/src/tools/log/log.interfaces.js +1 -1
  104. package/bundle/obf/src/tools/spawn-async/spawn-async.class.js +1 -1
  105. package/bundle/obf/src/tools/spawn-async/spawn-async.interfaces.js +1 -1
  106. package/bundle/obf/src/tools/ssh/ssh.class.js +1 -1
  107. package/bundle/obf/src/tools/ssh/ssh.interfaces.js +1 -1
  108. package/bundle/obf/src/tools/ssl/ssl.class.js +1 -1
  109. package/package.json +1 -1
@@ -1 +1 @@
1
- function a70d(a,b){const c=a70c();return a70d=function(d,e){d=d-0x1eb;let f=c[d];return f;},a70d(a,b);}const a70k=a70d;(function(a,b){const h=a70d,c=a();while(!![]){try{const d=parseInt(h(0x1fb))/0x1*(parseInt(h(0x1f0))/0x2)+-parseInt(h(0x1fd))/0x3*(parseInt(h(0x1f6))/0x4)+-parseInt(h(0x1f8))/0x5+parseInt(h(0x204))/0x6+parseInt(h(0x1f7))/0x7+-parseInt(h(0x1ed))/0x8*(-parseInt(h(0x200))/0x9)+-parseInt(h(0x1f3))/0xa;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a70c,0xa9330));const a70b=(function(){let a=!![];return function(b,c){const d=a?function(){const i=a70d;if(c){const e=c[i(0x1eb)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a70a=a70b(this,function(){const j=a70d;return a70a[j(0x1f2)]()['search'](j(0x202))['toString']()['constructor'](a70a)[j(0x1f1)](j(0x202));});function a70c(){const n=['90432jBgHHB','apply','injectAtEndOfFile','273896kiAYFf','getProjectConfig','server/publish.','2zowvNf','search','toString','16800940jwiIfO','publish','maka\x20{generate,\x20g}:{publish,\x20p}\x20<name>','212268rbNeum','8022728EKsxOI','1791470okNJlq','fsi','engines','964255pxHFHN','withValue','18WJJdEF','Scaffolding\x20for\x20a\x20publish\x20function.\x0ahttps://docs.meteor.com/api/pubsub.html','resourceName','243CZTjKq','rewriteDestinationPathForEngine','(((.+)+)+)+$','tsx'];a70c=function(){return n;};return a70c();}a70a();import{paramCase}from'change-case';import{Generator}from'../generator.js';Generator['create']({'name':a70k(0x1f4),'aliases':['p'],'usage':a70k(0x1f5),'shortDesc':a70k(0x1fe),'validOpts':[],'examples':['maka\x20g:publish\x20todos']},async function(a,b){const l=a70k,c=this[l(0x1f9)][l(0x1ee)]();this['fsi'][l(0x1fc)](c,async()=>{const m=l,d={'name':b[m(0x1ff)],'collection':paramCase(b[m(0x1ff)]),'noRename':!![]};let e='js';c[m(0x1fa)]['js']===m(0x203)&&(e='ts');const f=this['fsi'][m(0x201)]({'pathParts':[m(0x1ef)+c[m(0x1fa)]['js']]}),g=this[m(0x1f9)]['templateContent']({'srcPath':'publish/publish.'+e,'context':d,'config':c});this[m(0x1f9)][m(0x1ec)]({'filePath':f,'content':'\x0a'+g});});});
1
+ function a70c(){const n=['toString','resourceName','12ISepVG','49291SRSZrZ','tsx','maka\x20{generate,\x20g}:{publish,\x20p}\x20<name>','1338245lthEUq','apply','create','4920Umhuzc','server/publish.','850428qUjgpR','25NSpLua','15112GTzDsj','(((.+)+)+)+$','18OrUEyt','Scaffolding\x20for\x20a\x20publish\x20function.\x0ahttps://docs.meteor.com/api/pubsub.html','145154LHKntd','engines','templateContent','getProjectConfig','756SczjJk','9260784UuwLuH','search','18689770ekpkDb','fsi'];a70c=function(){return n;};return a70c();}const a70k=a70d;function a70d(a,b){const c=a70c();return a70d=function(d,e){d=d-0x140;let f=c[d];return f;},a70d(a,b);}(function(a,b){const h=a70d,c=a();while(!![]){try{const d=-parseInt(h(0x149))/0x1*(-parseInt(h(0x14e))/0x2)+parseInt(h(0x159))/0x3*(-parseInt(h(0x148))/0x4)+parseInt(h(0x143))/0x5*(-parseInt(h(0x14c))/0x6)+-parseInt(h(0x152))/0x7*(parseInt(h(0x14a))/0x8)+parseInt(h(0x153))/0x9+-parseInt(h(0x155))/0xa+parseInt(h(0x140))/0xb*(parseInt(h(0x146))/0xc);if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a70c,0xe8f87));const a70b=(function(){let a=!![];return function(b,c){const d=a?function(){const i=a70d;if(c){const e=c[i(0x144)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a70a=a70b(this,function(){const j=a70d;return a70a[j(0x157)]()[j(0x154)]('(((.+)+)+)+$')[j(0x157)]()['constructor'](a70a)[j(0x154)](j(0x14b));});a70a();import{paramCase}from'change-case';import{Generator}from'../generator.js';Generator[a70k(0x145)]({'name':'publish','aliases':['p'],'usage':a70k(0x142),'shortDesc':a70k(0x14d),'validOpts':[],'examples':['maka\x20g:publish\x20todos']},async function(a,b){const l=a70k,c=this[l(0x156)][l(0x151)]();this[l(0x156)]['withValue'](c,async()=>{const m=l,d={'name':b['resourceName'],'collection':paramCase(b[m(0x158)]),'noRename':!![]};let e='js';c[m(0x14f)]['js']===m(0x141)&&(e='ts');const f=this[m(0x156)]['rewriteDestinationPathForEngine']({'pathParts':[m(0x147)+c[m(0x14f)]['js']]}),g=this['fsi'][m(0x150)]({'srcPath':'publish/publish.'+e,'context':d,'config':c});this[m(0x156)]['injectAtEndOfFile']({'filePath':f,'content':'\x0a'+g});});});
@@ -1 +1 @@
1
- function a71c(){const H=['34QuSTjC','rewriteDestinationPathForEngine','maka\x20{generate,\x20g}:{route,\x20r}\x20[path/]<name>\x20[url]\x20[--private]','search','342251Uqasgd','maka\x20g:route\x20lists/listIndex\x20lists','apply','60715DeDFcK','toString','(((.+)+)+)+$','root','1451079ozHxFC','length','imports','maka\x20g:route\x20todosEdit\x20todos/:id/edit','cwd','config','injectIntoFile','react','templateName','layout','\x0a\x09\x09','join','Scaffolding\x20for\x20a\x20Route.','indexOf','filter','create','220521zhNkJz','lib','MasterLayout','maka\x20g:route\x20usersShow\x20users/:id/show\x20--layout\x20userView','routes.js','import\x20*\x20as\x20Component\x20from\x20\x27./templates\x27;','route/route.js','maka\x20g:route\x20todosIndex\x20todos','map','691200SXhoTO','only','injectAfterLineNumber','client','36148970orrYuy','includes','private','160143grtARR','ssr','templateContent','startup','const\x20publicRoutes\x20=\x20(<>','error','readFileLines','getProjectConfig','withValue','pathFromApp','const\x20privateRoutes\x20=\x20(<>','66ANmyJb','276XpQocv','fsi','<Router','engines','16RbshOs','page','Could\x20not\x20find\x20a\x20suitable\x20location\x20to\x20enable\x20this\x20route.\x20\x20Please\x20inspect\x20','features','findGenerator'];a71c=function(){return H;};return a71c();}const a71y=a71d;(function(a,b){const v=a71d,c=a();while(!![]){try{const d=-parseInt(v(0x73))/0x1+parseInt(v(0x6f))/0x2*(-parseInt(v(0x9a))/0x3)+-parseInt(v(0x66))/0x4*(parseInt(v(0x76))/0x5)+parseInt(v(0x65))/0x6*(-parseInt(v(0x8a))/0x7)+-parseInt(v(0x6a))/0x8*(parseInt(v(0x7a))/0x9)+-parseInt(v(0x93))/0xa+parseInt(v(0x97))/0xb;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a71c,0x70710));function a71d(a,b){const c=a71c();return a71d=function(d,e){d=d-0x64;let f=c[d];return f;},a71d(a,b);}const a71b=(function(){let a=!![];return function(b,c){const d=a?function(){const w=a71d;if(c){const e=c[w(0x75)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a71a=a71b(this,function(){const x=a71d;return a71a['toString']()[x(0x72)](x(0x78))[x(0x77)]()['constructor'](a71a)[x(0x72)](x(0x78));});a71a();import a71e from'path';import{Generator}from'../generator.js';import{Log}from'../tools/log/log.class.js';import a71f from'../generators/maka.gen.js';import{camelCase,paramCase,pascalCase}from'change-case';const aliases=['r'];Generator[a71y(0x89)]({'name':'route','aliases':aliases,'validOpts':[a71y(0x99),'layout',a71y(0x94),a71y(0x7e),a71y(0x7f),a71y(0x79),'withHook'],'usage':a71y(0x71),'shortDesc':a71y(0x86),'examples':[a71y(0x91),a71y(0x7d),a71y(0x8d),a71y(0x74)]},function(a,b){const z=a71y;try{const c=this[z(0x67)][z(0xa1)]();this[z(0x67)][z(0xa2)](c,async()=>{const A=z,d=b[A(0x99)]??![];let f=paramCase(a[0x0]),g='/'+f;a['length']>0x1&&(g='/'+a[A(0x88)](function(l){return l!=='/';})[A(0x85)]('/')['toLowerCase']());f=camelCase(f);b['layout']&&(b[A(0x83)]=camelCase(b[A(0x83)]));const h=a71e[A(0x85)]('/imports/ui/pages',f,f),i={'name':f,'fileCase':paramCase(f),'camelCaseName':camelCase(f),'url':g,'layout':b[A(0x83)]||A(0x8c),'templatePath':h,'templateName':pascalCase(f),'client':c[A(0x69)][A(0x96)],'newForm':![],'withTranslations':c[A(0x6d)]['withTranslations']};d&&(i[A(0x83)]='PrivateLayout');if(!b[A(0x79)]){const l=a71f[A(0x6e)](A(0x6b));l&&await l['invoke'](a,b);}let j,k;if(c[A(0x69)][A(0x96)]===A(0x81)){if(c[A(0x69)][A(0x9b)]==='true'){const p=this[A(0x67)][A(0xa3)]({'pathParts':[A(0x7c),A(0x9d),A(0x8b),A(0x8e)]});j=this[A(0x67)][A(0x70)]({'pathParts':[p],'config':c});}else{const q=this[A(0x67)]['pathFromApp']({'pathParts':['imports',A(0x9d),A(0x96),A(0x8e)]});j=this[A(0x67)]['rewriteDestinationPathForEngine']({'pathParts':[q],'config':c});}const m=this[A(0x67)][A(0xa0)](j)[A(0x92)]((r,s)=>{const B=A;return r[B(0x98)](B(0x8f))?s+0x1:null;})[A(0x88)](r=>r!==null);let n=this['fsi'][A(0xa0)](j)['map']((r,s)=>{const C=A;return r[C(0x98)]('const\x20publicRoutes\x20=\x20(<>')?s+0x1:null;})['filter'](r=>r!==null),o=this[A(0x67)][A(0xa0)](j)[A(0x92)]((r,s)=>{const D=A;return r[D(0x98)]('const\x20privateRoutes\x20=\x20(<>')?s+0x1:null;})[A(0x88)](r=>r!==null);n[A(0x7b)]>0x0&&o[A(0x7b)]>0x0&&(i['newForm']=!![]);k=this[A(0x67)][A(0x9c)]({'srcPath':A(0x90),'framework':A(0x81),'context':i,'config':c});if(n[A(0x7b)]>0x0||o[A(0x7b)]>0x0){this[A(0x67)]['injectAfterLineNumber']({'filePath':j,'content':k,'lineNumber':m[0x0]});if(d&&o[A(0x7b)]>0x0)o=this['fsi']['readFileLines'](j)[A(0x92)]((r,s)=>{const E=A;return r[E(0x98)](E(0x64))?s+0x1:null;})['filter'](r=>r!==null),this['fsi']['injectAfterLineNumber']({'filePath':j,'content':'\x09{'+i[A(0x82)]+'}','lineNumber':o[0x0]});else n[A(0x7b)]>0x0?(n=this[A(0x67)]['readFileLines'](j)[A(0x92)]((r,s)=>{const F=A;return r[F(0x98)](F(0x9e))?s+0x1:null;})[A(0x88)](r=>r!==null),this[A(0x67)][A(0x95)]({'filePath':j,'content':'\x09{'+i[A(0x82)]+'}','lineNumber':n[0x0]})):Log['warn'](A(0x6c)+j);}else{const r=this[A(0x67)][A(0xa0)](j)[A(0x92)](u=>{const G=A;return u[G(0x98)]('\x22*\x22');}),s=r[A(0x87)](!![])>-0x1,t=s?'<Route':'</Router>';this[A(0x67)][A(0x80)]({'filePath':j,'content':A(0x84)+k+'\x0a\x09\x09','begin':A(0x68),'end':t});}}else{if(c[A(0x69)][A(0x96)]==='vanilla'){const u=this[A(0x67)]['pathFromApp']({'pathParts':[A(0x7c),A(0x9d),'client',A(0x8e)]});j=this[A(0x67)]['rewriteDestinationPathForEngine']({'pathParts':[u],'config':c}),k=this[A(0x67)]['templateContent']({'srcPath':A(0x90),'context':i}),this[A(0x67)]['injectAtEndOfFile']({'filePath':j,'content':'\x0a'+k});}}});}catch(d){Log[z(0x9f)](d);}});
1
+ function a71d(a,b){const c=a71c();return a71d=function(d,e){d=d-0x148;let f=c[d];return f;},a71d(a,b);}const a71x=a71d;(function(a,b){const v=a71d,c=a();while(!![]){try{const d=parseInt(v(0x16e))/0x1*(parseInt(v(0x159))/0x2)+-parseInt(v(0x168))/0x3+-parseInt(v(0x184))/0x4*(-parseInt(v(0x180))/0x5)+parseInt(v(0x15d))/0x6*(-parseInt(v(0x14a))/0x7)+parseInt(v(0x158))/0x8*(parseInt(v(0x163))/0x9)+-parseInt(v(0x172))/0xa+-parseInt(v(0x148))/0xb*(-parseInt(v(0x17e))/0xc);if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a71c,0x4bf18));const a71b=(function(){let a=!![];return function(b,c){const d=a?function(){if(c){const e=c['apply'](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a71a=a71b(this,function(){const w=a71d;return a71a[w(0x152)]()['search']('(((.+)+)+)+$')[w(0x152)]()[w(0x16d)](a71a)['search'](w(0x14b));});a71a();import a71e from'path';import{Generator}from'../generator.js';import{Log}from'../tools/log/log.class.js';import a71f from'../generators/maka.gen.js';import{camelCase,paramCase,pascalCase}from'change-case';const aliases=['r'];Generator['create']({'name':'route','aliases':aliases,'validOpts':[a71x(0x15f),a71x(0x161),a71x(0x17f),a71x(0x171),a71x(0x167),'root',a71x(0x156),a71x(0x153)],'usage':'maka\x20{generate,\x20g}:{route,\x20r}\x20[path/]<name>\x20[url]\x20[--private]','shortDesc':'Scaffolding\x20for\x20a\x20Route.','examples':['maka\x20g:route\x20todosIndex\x20todos','maka\x20g:route\x20todosEdit\x20todos/:id/edit',a71x(0x17b),'maka\x20g:route\x20lists/listIndex\x20lists']},function(a,b){const y=a71x;try{const c=this[y(0x14c)][y(0x162)]();this[y(0x14c)][y(0x154)](c,async()=>{const z=y,d=b[z(0x15f)]??![];let f=paramCase(a[0x0]),g='/'+f;a[z(0x174)]>0x1&&(g='/'+a['filter'](function(l){return l!=='/';})[z(0x169)]('/')[z(0x17d)]());f=camelCase(f);b[z(0x161)]&&(b[z(0x161)]=camelCase(b[z(0x161)]));const h=a71e[z(0x169)](z(0x160),f,f),i={'name':f,'fileCase':paramCase(f),'camelCaseName':camelCase(f),'url':g,'layout':b[z(0x161)]||z(0x16f),'templatePath':h,'templateName':pascalCase(f),'client':c[z(0x15e)][z(0x15b)],'newForm':![],'withTranslations':c['features'][z(0x150)]};d&&(i['layout']='PrivateLayout');if(!b['root']){const l=a71f[z(0x14d)](z(0x17a));l&&await l['invoke'](a,b);}let j,k;if(c[z(0x15e)][z(0x15b)]===z(0x176)){if(c[z(0x15e)][z(0x155)]===z(0x170)){const p=this[z(0x14c)][z(0x14f)]({'pathParts':[z(0x177),'startup','lib','routes.js']});j=this['fsi']['rewriteDestinationPathForEngine']({'pathParts':[p],'config':c});}else{const q=this['fsi'][z(0x14f)]({'pathParts':['imports','startup',z(0x15b),z(0x14e)]});j=this['fsi'][z(0x149)]({'pathParts':[q],'config':c});}const m=this[z(0x14c)]['readFileLines'](j)[z(0x182)]((r,s)=>{const A=z;return r['includes'](A(0x157))?s+0x1:null;})[z(0x16a)](r=>r!==null);let n=this[z(0x14c)][z(0x179)](j)[z(0x182)]((r,s)=>{const B=z;return r['includes'](B(0x181))?s+0x1:null;})['filter'](r=>r!==null),o=this['fsi'][z(0x179)](j)[z(0x182)]((r,s)=>{return r['includes']('const\x20privateRoutes\x20=\x20(<>')?s+0x1:null;})[z(0x16a)](r=>r!==null);n[z(0x174)]>0x0&&o[z(0x174)]>0x0&&(i['newForm']=!![]);k=this[z(0x14c)][z(0x151)]({'srcPath':z(0x15c),'framework':z(0x176),'context':i,'config':c});if(n[z(0x174)]>0x0||o[z(0x174)]>0x0){this[z(0x14c)]['injectAfterLineNumber']({'filePath':j,'content':k,'lineNumber':m[0x0]});if(d&&o[z(0x174)]>0x0)o=this[z(0x14c)][z(0x179)](j)['map']((r,s)=>{const C=z;return r['includes'](C(0x16b))?s+0x1:null;})['filter'](r=>r!==null),this['fsi'][z(0x165)]({'filePath':j,'content':'\x09{'+i['templateName']+'}','lineNumber':o[0x0]});else n[z(0x174)]>0x0?(n=this[z(0x14c)]['readFileLines'](j)[z(0x182)]((r,s)=>{return r['includes']('const\x20publicRoutes\x20=\x20(<>')?s+0x1:null;})[z(0x16a)](r=>r!==null),this[z(0x14c)][z(0x165)]({'filePath':j,'content':'\x09{'+i[z(0x185)]+'}','lineNumber':n[0x0]})):Log['warn']('Could\x20not\x20find\x20a\x20suitable\x20location\x20to\x20enable\x20this\x20route.\x20\x20Please\x20inspect\x20'+j);}else{const r=this['fsi'][z(0x179)](j)['map'](u=>{const D=z;return u['includes'](D(0x178));}),s=r[z(0x166)](!![])>-0x1,t=s?z(0x173):'</Router>';this[z(0x14c)][z(0x175)]({'filePath':j,'content':z(0x183)+k+z(0x183),'begin':z(0x15a),'end':t});}}else{if(c[z(0x15e)][z(0x15b)]===z(0x164)){const u=this['fsi'][z(0x14f)]({'pathParts':[z(0x177),z(0x17c),z(0x15b),z(0x14e)]});j=this[z(0x14c)][z(0x149)]({'pathParts':[u],'config':c}),k=this[z(0x14c)][z(0x151)]({'srcPath':z(0x15c),'context':i}),this[z(0x14c)]['injectAtEndOfFile']({'filePath':j,'content':'\x0a'+k});}}});}catch(d){Log[y(0x16c)](d);}});function a71c(){const E=['route/route.js','324vlBijU','engines','private','/imports/ui/pages','layout','getProjectConfig','72zwMHdq','vanilla','injectAfterLineNumber','indexOf','config','1598805qZjtzP','join','filter','const\x20privateRoutes\x20=\x20(<>','error','constructor','29582jePUVt','MasterLayout','true','cwd','3456360SLCpxY','<Route','length','injectIntoFile','react','imports','\x22*\x22','readFileLines','page','maka\x20g:route\x20usersShow\x20users/:id/show\x20--layout\x20userView','startup','toLowerCase','7944VTEPBs','only','35OQnLwR','const\x20publicRoutes\x20=\x20(<>','map','\x0a\x09\x09','231524QOxJrX','templateName','9427rtyYrd','rewriteDestinationPathForEngine','49133PGknhu','(((.+)+)+)+$','fsi','findGenerator','routes.js','pathFromApp','withTranslations','templateContent','toString','url','withValue','ssr','withHook','import\x20*\x20as\x20Component\x20from\x20\x27./templates\x27;','477832guFZvn','8HTChsr','<Router','client'];a71c=function(){return E;};return a71c();}
@@ -1 +1 @@
1
- const a72l=a72d;(function(a,b){const j=a72d,c=a();while(!![]){try{const d=-parseInt(j(0xcd))/0x1+-parseInt(j(0xd2))/0x2+parseInt(j(0xbd))/0x3+-parseInt(j(0xd4))/0x4*(-parseInt(j(0xcc))/0x5)+-parseInt(j(0xba))/0x6*(parseInt(j(0xce))/0x7)+parseInt(j(0xd5))/0x8*(-parseInt(j(0xc0))/0x9)+parseInt(j(0xc8))/0xa;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a72c,0x25ad3));function a72d(a,b){const c=a72c();return a72d=function(d,e){d=d-0xb6;let f=c[d];return f;},a72d(a,b);}function a72c(){const o=['search','engines','services','maka\x20{generate,\x20g}:{service}\x20[service-type]','withValue','pathFromApp','logger','786042oOExhM','type','lib','913143jFryba','(((.+)+)+)+$','Installing\x20winston','9ESBUbj','resourceName','svc','toString','fsi','installNpmPackage','winston\x20setimmediate','constructor','933060pwERfG','tsx','create','getProjectConfig','360vjknLA','37510IBtYNs','7LICvWD','Generate\x20a\x20service\x20to\x20run\x20within\x20your\x20meteor\x20application.','maka\x20g:svc\x20logger','winston','316796meICIZ','service/logger/logger.js','13084JqOapo','1215688tqVrsf','checkNpmPackage','startup'];a72c=function(){return o;};return a72c();}const a72b=(function(){let a=!![];return function(b,c){const d=a?function(){if(c){const e=c['apply'](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a72a=a72b(this,function(){const k=a72d;return a72a[k(0xc3)]()[k(0xd8)](k(0xbe))[k(0xc3)]()[k(0xc7)](a72a)[k(0xd8)]('(((.+)+)+)+$');});a72a();import{camelCase,paramCase,pascalCase}from'change-case';import{Generator}from'../generator.js';import{Log}from'../tools/log/log.class.js';Generator[a72l(0xca)]({'name':'service','aliases':[a72l(0xc2)],'usage':a72l(0xb6),'shortDesc':a72l(0xcf),'validOpts':[a72l(0xbb)],'validArgs':[a72l(0xb9)],'maxArgLength':0x1,'minArgLength':0x1,'examples':[a72l(0xd0)]},async function(a,b){const m=a72l;try{const c=this[m(0xc4)][m(0xcb)]();this[m(0xc4)][m(0xb7)](c,async()=>{const n=m,d=this[n(0xc4)][n(0xb8)]({}),f=paramCase(b['resourceName']),g={'name':pascalCase(b[n(0xc1)]),'fileName':f,'camelCase':camelCase(b[n(0xc1)]),'type':a[0x0],'engine':c[n(0xd9)]['js'],'noRename':!![]};let h='js';c[n(0xd9)]['js']===n(0xc9)&&(h='ts');if(a[0x0]==='logger'){!this['fsi'][n(0xd6)](n(0xd1))&&await this[n(0xc4)][n(0xc5)](n(0xc6),{'cwd':d,'msg':n(0xbf)});const i=this[n(0xc4)][n(0xb8)]({'pathParts':['imports',n(0xd7),n(0xbc),n(0xda),f+'.'+h]});this[n(0xc4)]['template']({'srcPath':n(0xd3),'destPath':i,'context':g,'config':c});}});}catch(d){Log['error'](d);}});
1
+ const a72l=a72d;(function(a,b){const j=a72d,c=a();while(!![]){try{const d=-parseInt(j(0x13f))/0x1*(-parseInt(j(0x144))/0x2)+-parseInt(j(0x15d))/0x3+-parseInt(j(0x15a))/0x4+parseInt(j(0x141))/0x5*(-parseInt(j(0x160))/0x6)+-parseInt(j(0x155))/0x7*(-parseInt(j(0x150))/0x8)+parseInt(j(0x143))/0x9*(-parseInt(j(0x146))/0xa)+parseInt(j(0x152))/0xb;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a72c,0x7fc3f));const a72b=(function(){let a=!![];return function(b,c){const d=a?function(){if(c){const e=c['apply'](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a72a=a72b(this,function(){const k=a72d;return a72a['toString']()[k(0x14b)](k(0x148))[k(0x145)]()['constructor'](a72a)['search']('(((.+)+)+)+$');});a72a();import{camelCase,paramCase,pascalCase}from'change-case';function a72c(){const o=['(((.+)+)+)+$','maka\x20g:svc\x20logger','engines','search','pathFromApp','getProjectConfig','service','checkNpmPackage','32XOUKRa','imports','4395380lVMPzc','startup','Installing\x20winston','1809542yPUTQR','svc','resourceName','lib','Generate\x20a\x20service\x20to\x20run\x20within\x20your\x20meteor\x20application.','3047532dNuhbE','winston','create','3045078amUQPl','logger','error','6WDCIVy','maka\x20{generate,\x20g}:{service}\x20[service-type]','service/logger/logger.js','withValue','141557aDkIoC','fsi','109115ePqiVa','services','76833QvanMl','14BSQTjb','toString','120mPhlZv','type'];a72c=function(){return o;};return a72c();}import{Generator}from'../generator.js';import{Log}from'../tools/log/log.class.js';function a72d(a,b){const c=a72c();return a72d=function(d,e){d=d-0x13e;let f=c[d];return f;},a72d(a,b);}Generator[a72l(0x15c)]({'name':a72l(0x14e),'aliases':[a72l(0x156)],'usage':a72l(0x161),'shortDesc':a72l(0x159),'validOpts':[a72l(0x147)],'validArgs':[a72l(0x15e)],'maxArgLength':0x1,'minArgLength':0x1,'examples':[a72l(0x149)]},async function(a,b){const m=a72l;try{const c=this[m(0x140)][m(0x14d)]();this[m(0x140)][m(0x13e)](c,async()=>{const n=m,d=this[n(0x140)][n(0x14c)]({}),f=paramCase(b['resourceName']),g={'name':pascalCase(b[n(0x157)]),'fileName':f,'camelCase':camelCase(b[n(0x157)]),'type':a[0x0],'engine':c[n(0x14a)]['js'],'noRename':!![]};let h='js';c['engines']['js']==='tsx'&&(h='ts');if(a[0x0]===n(0x15e)){!this['fsi'][n(0x14f)](n(0x15b))&&await this[n(0x140)]['installNpmPackage']('winston\x20setimmediate',{'cwd':d,'msg':n(0x154)});const i=this[n(0x140)][n(0x14c)]({'pathParts':[n(0x151),n(0x153),n(0x158),n(0x142),f+'.'+h]});this[n(0x140)]['template']({'srcPath':n(0x162),'destPath':i,'context':g,'config':c});}});}catch(d){Log[m(0x15f)](d);}});
@@ -1 +1 @@
1
- (function(a,b){var f=a73d,c=a();while(!![]){try{var d=parseInt(f(0x17a))/0x1*(parseInt(f(0x184))/0x2)+parseInt(f(0x17d))/0x3+-parseInt(f(0x183))/0x4*(-parseInt(f(0x188))/0x5)+parseInt(f(0x186))/0x6*(-parseInt(f(0x185))/0x7)+parseInt(f(0x17e))/0x8+parseInt(f(0x17f))/0x9+-parseInt(f(0x181))/0xa*(parseInt(f(0x180))/0xb);if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a73c,0x458f7));function a73c(){var i=['15KWaocv','apply','251qwUkAE','search','toString','1359558THNprE','3750688KuelWc','3068802samNzf','4279aeuZQz','26570xBMJPj','(((.+)+)+)+$','370632ZcYahs','2238MNrkXl','3523457mcOeuO','6FOXBdc','constructor'];a73c=function(){return i;};return a73c();}var a73b=(function(){var a=!![];return function(b,c){var d=a?function(){var g=a73d;if(c){var e=c[g(0x189)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a73a=a73b(this,function(){var h=a73d;return a73a[h(0x17c)]()['search']('(((.+)+)+)+$')[h(0x17c)]()[h(0x187)](a73a)[h(0x17b)](h(0x182));});function a73d(a,b){var c=a73c();return a73d=function(d,e){d=d-0x17a;var f=c[d];return f;},a73d(a,b);}a73a();import'./translation.js';import'./openssl.js';
1
+ (function(a,b){var f=a73d,c=a();while(!![]){try{var d=parseInt(f(0x1c1))/0x1*(parseInt(f(0x1c0))/0x2)+-parseInt(f(0x1c2))/0x3+-parseInt(f(0x1c3))/0x4+parseInt(f(0x1be))/0x5+-parseInt(f(0x1c4))/0x6*(-parseInt(f(0x1c5))/0x7)+parseInt(f(0x1c7))/0x8+parseInt(f(0x1c6))/0x9;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a73c,0x74d13));function a73c(){var i=['constructor','6IxhWaY','79087HILMrn','2252361jdjXWZ','3406108hHydqV','1653810GChJBE','21ylgpBt','2318391txIBlP','4410648HFQWPb','apply','toString','(((.+)+)+)+$','search','1038505xJUOLS'];a73c=function(){return i;};return a73c();}var a73b=(function(){var a=!![];return function(b,c){var d=a?function(){var g=a73d;if(c){var e=c[g(0x1c8)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a73a=a73b(this,function(){var h=a73d;return a73a['toString']()['search'](h(0x1bc))[h(0x1c9)]()[h(0x1bf)](a73a)[h(0x1bd)](h(0x1bc));});function a73d(a,b){var c=a73c();return a73d=function(d,e){d=d-0x1bc;var f=c[d];return f;},a73d(a,b);}a73a();import'./translation.js';import'./openssl.js';
@@ -1 +1 @@
1
- function a74c(){const n=['template','getConfigPath','withValue','8260479bUAmDh','16lFjvem','fsi','error','service','Generate\x20a\x20new\x20openssl\x20config\x20file','maka\x20g:sslconfig\x20--env\x20dev','88EYeGMI','getGlobalConfig','sslconfig','toString','search','maka\x20{generate,\x20g}:sslconfig','14742rvvMQn','getProjectConfig','1090920RbUUtK','env','create','166908wvYVcG','208629FOxmiF','(((.+)+)+)+$','openssl.conf','constructor','1758895EWjbNK','213433KNivNK'];a74c=function(){return n;};return a74c();}const a74k=a74d;(function(a,b){const i=a74d,c=a();while(!![]){try{const d=parseInt(i(0x141))/0x1+-parseInt(i(0x13b))/0x2+parseInt(i(0x13c))/0x3*(-parseInt(i(0x146))/0x4)+-parseInt(i(0x140))/0x5+-parseInt(i(0x154))/0x6+parseInt(i(0x152))/0x7*(-parseInt(i(0x14c))/0x8)+parseInt(i(0x145))/0x9;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a74c,0x33f89));const a74b=(function(){let a=!![];return function(b,c){const d=a?function(){if(c){const e=c['apply'](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a74a=a74b(this,function(){const j=a74d;return a74a[j(0x14f)]()['search']('(((.+)+)+)+$')[j(0x14f)]()[j(0x13f)](a74a)[j(0x150)](j(0x13d));});a74a();import{Generator}from'../../generator.js';import{Log}from'../../tools/log/log.class.js';function a74d(a,b){const c=a74c();return a74d=function(d,e){d=d-0x13a;let f=c[d];return f;},a74d(a,b);}import a74e from'path';Generator[a74k(0x13a)]({'name':a74k(0x14e),'usage':a74k(0x151),'shortDesc':a74k(0x14a),'noResource':!![],'requiredOpts':[a74k(0x155)],'examples':[a74k(0x14b)],'validOpts':['env']},async function(a,b){const l=a74k;try{const c=await this[l(0x147)][l(0x153)](),d=await this['fsi'][l(0x14d)](),f=this['fsi'][l(0x143)](b[l(0x155)]),g=a74e['join'](f,'_keys',l(0x13e));await this[l(0x147)][l(0x144)](c,async()=>{const m=l,h={'app':d['appName'],'noRename':!![]};await this[m(0x147)][m(0x142)]({'srcPath':'openssl/openssl.conf','destPath':g,'framework':m(0x149),'context':h,'config':c});});}catch(h){Log[l(0x148)](h);}});
1
+ function a74c(){const o=['getGlobalConfig','fsi','appName','4oIioam','toString','(((.+)+)+)+$','getProjectConfig','openssl.conf','constructor','template','error','615hHuCyn','2577393InOudA','apply','maka\x20g:sslconfig\x20--env\x20dev','1110016aVgTSn','148320EVbesp','maka\x20{generate,\x20g}:sslconfig','env','getConfigPath','service','144348FOkoXg','openssl/openssl.conf','1028AiXHxi','_keys','610526ttRjwL','72985TNiWIm'];a74c=function(){return o;};return a74c();}const a74l=a74d;(function(a,b){const i=a74d,c=a();while(!![]){try{const d=-parseInt(i(0xcf))/0x1+-parseInt(i(0xcc))/0x2*(parseInt(i(0xc0))/0x3)+-parseInt(i(0xd3))/0x4*(-parseInt(i(0xc5))/0x5)+parseInt(i(0xca))/0x6+parseInt(i(0xce))/0x7+-parseInt(i(0xc4))/0x8+parseInt(i(0xc1))/0x9;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a74c,0x1ae82));const a74b=(function(){let a=!![];return function(b,c){const d=a?function(){const j=a74d;if(c){const e=c[j(0xc2)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a74a=a74b(this,function(){const k=a74d;return a74a[k(0xd4)]()['search'](k(0xba))['toString']()[k(0xbd)](a74a)['search'](k(0xba));});a74a();function a74d(a,b){const c=a74c();return a74d=function(d,e){d=d-0xba;let f=c[d];return f;},a74d(a,b);}import{Generator}from'../../generator.js';import{Log}from'../../tools/log/log.class.js';import a74e from'path';Generator['create']({'name':'sslconfig','usage':a74l(0xc6),'shortDesc':'Generate\x20a\x20new\x20openssl\x20config\x20file','noResource':!![],'requiredOpts':[a74l(0xc7)],'examples':[a74l(0xc3)],'validOpts':[a74l(0xc7)]},async function(a,b){const m=a74l;try{const c=await this['fsi'][m(0xbb)](),d=await this[m(0xd1)][m(0xd0)](),f=this['fsi'][m(0xc8)](b[m(0xc7)]),g=a74e['join'](f,m(0xcd),m(0xbc));await this[m(0xd1)]['withValue'](c,async()=>{const n=m,h={'app':d[n(0xd2)],'noRename':!![]};await this[n(0xd1)][n(0xbe)]({'srcPath':n(0xcb),'destPath':g,'framework':n(0xc9),'context':h,'config':c});});}catch(h){Log[m(0xbf)](h);}});
@@ -1 +1 @@
1
- const a75A=a75d;(function(a,b){const x=a75d,c=a();while(!![]){try{const d=-parseInt(x(0x12e))/0x1+-parseInt(x(0x142))/0x2*(-parseInt(x(0x14e))/0x3)+parseInt(x(0x144))/0x4+-parseInt(x(0x130))/0x5*(-parseInt(x(0x148))/0x6)+-parseInt(x(0x14f))/0x7*(-parseInt(x(0x122))/0x8)+-parseInt(x(0x10d))/0x9*(parseInt(x(0x137))/0xa)+parseInt(x(0x11b))/0xb*(-parseInt(x(0x116))/0xc);if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a75c,0xb63a4));function a75c(){const D=['locales','injectAtBeginningOfFile','installNpmPackage','73426ogezRO','import\x20\x27../lib/services/translations/i18n\x27;\x0a','3779780VkIYnp','readFileSync','apply','Generate\x20a\x20new\x20locale\x20translation','12TuaVvR','translation','lang','import\x20\x27../lib/services/translations/i18n\x27;','index.','setProjectConfig','60rGZuds','7GfREDz','rewriteDestinationPathForEngine','default\x20as\x20','3590361JMyPAX','template','translations','imports','grep','withValue','toString','export\x20{\x20default\x20as\x20','exit','8148DlvyTP','error','engines','lib','injectAtEndOfFile','11033kThWnK','(((.+)+)+)+$','.js','warn','findAppDirectory','getProjectConfig','i18n/i18n.js','1761128ZAFVmo','getGlobalConfig','server','fsi','maka\x20g:translation\x20--lang=fr','index.js','pathFromApp','startup','service','root','i18n.js','ssr','113234XzcAEk','maka\x20g:translation\x20--lang=de','100645ljfPKG','Locale\x20already\x20exported:\x20','appName','maka\x20{generate,\x20g}:translation\x20--lang=<language>','true','constructor','search','10neZYlM','services','Verifying\x20npm\x20package\x20requirements:\x20i18next\x20...','features.withTranslations','Locale\x20already\x20defined:\x20','isFile','create','i18n'];a75c=function(){return D;};return a75c();}const a75b=(function(){let a=!![];return function(b,c){const d=a?function(){const y=a75d;if(c){const e=c[y(0x146)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a75a=a75b(this,function(){const z=a75d;return a75a[z(0x113)]()[z(0x136)](z(0x11c))[z(0x113)]()[z(0x135)](a75a)[z(0x136)](z(0x11c));});a75a();function a75d(a,b){const c=a75c();return a75d=function(d,e){d=d-0x10d;let f=c[d];return f;},a75d(a,b);}import{Generator}from'../../generator.js';import{Log}from'../../tools/log/log.class.js';import a75e from'fs';Generator[a75A(0x13d)]({'name':a75A(0x149),'usage':a75A(0x133),'aliases':[a75A(0x13e)],'shortDesc':a75A(0x147),'noResource':!![],'examples':['maka\x20g:translation\x20--lang=en\x20(default)',a75A(0x126),a75A(0x12f)],'validOpts':[a75A(0x14a)]},function(a,b){const B=a75A;try{const c=this[B(0x125)][B(0x120)](),d=this[B(0x125)][B(0x123)](),f=this['fsi'][B(0x11f)]();this[B(0x125)][B(0x112)](c,()=>{const C=B;try{!b['lang']&&(b['lang']='en');!b[C(0x12b)]&&!this[C(0x125)]['checkNpmPackage']('i18next')&&(Log['warn'](C(0x139)),this['fsi'][C(0x141)]('i18next\x20i18next-browser-languagedetector\x20react-i18next',{'cwd':f}),this[C(0x125)][C(0x14d)](C(0x13a),!![]));const g=this[C(0x125)][C(0x128)]({'pathParts':[C(0x110),C(0x129),'client',C(0x127)]}),h=this[C(0x125)]['rewriteDestinationPathForEngine']({'pathParts':[g],'config':c}),i=this[C(0x125)][C(0x111)](a75e[C(0x145)](h)[C(0x113)](),C(0x14b))[0x0]&&!![];if(c[C(0x118)][C(0x12d)]===C(0x134)){!i&&this[C(0x125)][C(0x140)]({'filePath':h,'content':'import\x20\x27../lib/services/translations/i18n\x27;\x0a'});const t=this[C(0x125)][C(0x128)]({'pathParts':[C(0x110),C(0x129),C(0x124),C(0x127)]}),u=this[C(0x125)][C(0x150)]({'pathParts':[t],'config':c}),v=this[C(0x125)]['grep'](a75e['readFileSync'](u)['toString'](),C(0x14b))[0x0]&&!![];!v&&this[C(0x125)]['injectAtBeginningOfFile']({'filePath':u,'content':'import\x20\x27../lib/services/translations/i18n\x27;\x0a'});}else!i&&this[C(0x125)][C(0x140)]({'filePath':h,'content':C(0x143)});const j={'app':d[C(0x132)],'config':c},k=this[C(0x125)][C(0x128)]({'pathParts':['imports',C(0x129),C(0x119),C(0x138),C(0x10f),C(0x12c)]}),l=this[C(0x125)][C(0x13c)](this[C(0x125)][C(0x150)]({'pathParts':[k],'config':c}));!l&&this[C(0x125)]['template']({'srcPath':C(0x121),'destPath':k,'framework':C(0x12a),'context':j,'config':c});const m=this[C(0x125)]['pathFromApp']({'pathParts':[C(0x110),C(0x129),C(0x119),C(0x138),C(0x10f),C(0x13f),b['lang']+C(0x11d)]}),n=this[C(0x125)][C(0x150)]({'pathParts':[m],'config':c}),o=this[C(0x125)]['isFile'](n);!o?this[C(0x125)][C(0x10e)]({'srcPath':'i18n/locales.js','destPath':m,'framework':C(0x12a),'context':j,'config':c}):Log['warn'](C(0x13b)+n);const p=this['fsi'][C(0x128)]({'pathParts':[C(0x110),C(0x129),'lib',C(0x138),C(0x10f),'locales',C(0x14c)+c['engines']['js']]}),q=this[C(0x125)]['rewriteDestinationPathForEngine']({'pathParts':[p],'config':c}),r=this['fsi'][C(0x13c)](q);!r&&this[C(0x125)]['template']({'srcPath':'i18n/index.js','destPath':p,'framework':'service','context':j,'config':c});const s=this[C(0x125)]['grep'](a75e[C(0x145)](p)[C(0x113)](),C(0x151)+b[C(0x14a)])[0x0]&&!![];!s?this[C(0x125)][C(0x11a)]({'filePath':p,'content':C(0x114)+b[C(0x14a)]+'\x20}\x20from\x20\x27./'+b[C(0x14a)]+'\x27;'}):Log[C(0x11e)](C(0x131)+p);}catch(w){Log[C(0x117)](w),process[C(0x115)](0x1);}});}catch(g){Log['error'](g),process[B(0x115)](0x1);}});
1
+ function a75d(a,b){const c=a75c();return a75d=function(d,e){d=d-0x179;let f=c[d];return f;},a75d(a,b);}function a75c(){const D=['20940SzgKiQ','i18next','isFile','installNpmPackage','findAppDirectory','index.js','rewriteDestinationPathForEngine','startup','(((.+)+)+)+$','591isvedh','lib','injectAtBeginningOfFile','lang','fsi','translations','root','index.','template','Locale\x20already\x20exported:\x20','i18next\x20i18next-browser-languagedetector\x20react-i18next','services','i18n/i18n.js','checkNpmPackage','grep','import\x20\x27../lib/services/translations/i18n\x27;\x0a','error','appName','getGlobalConfig','toString','i18n.js','i18n/index.js','readFileSync','7220tQGFPc','export\x20{\x20default\x20as\x20','1355BFgvJe','engines','service','7028848TAdpFm','Verifying\x20npm\x20package\x20requirements:\x20i18next\x20...','injectAtEndOfFile','features.withTranslations','setProjectConfig','true','warn','2270sJpzyJ','pathFromApp','search','imports','i18n/locales.js','exit','i18n','ssr','.js','7AxlbxR','6651150BKwdlI','4732776qdcQAN','locales','withValue','maka\x20g:translation\x20--lang=en\x20(default)','server','getProjectConfig','Generate\x20a\x20new\x20locale\x20translation','1658512YsKTbJ','apply','create','import\x20\x27../lib/services/translations/i18n\x27;'];a75c=function(){return D;};return a75c();}const a75A=a75d;(function(a,b){const x=a75d,c=a();while(!![]){try{const d=parseInt(x(0x19f))/0x1+parseInt(x(0x1ab))/0x2*(-parseInt(x(0x188))/0x3)+-parseInt(x(0x17b))/0x4+parseInt(x(0x1a1))/0x5*(-parseInt(x(0x17f))/0x6)+parseInt(x(0x1b4))/0x7*(parseInt(x(0x1a4))/0x8)+parseInt(x(0x1b6))/0x9+parseInt(x(0x1b5))/0xa;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a75c,0x784f8));const a75b=(function(){let a=!![];return function(b,c){const d=a?function(){const y=a75d;if(c){const e=c[y(0x17c)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a75a=a75b(this,function(){const z=a75d;return a75a[z(0x19b)]()[z(0x1ad)](z(0x187))[z(0x19b)]()['constructor'](a75a)[z(0x1ad)](z(0x187));});a75a();import{Generator}from'../../generator.js';import{Log}from'../../tools/log/log.class.js';import a75e from'fs';Generator[a75A(0x17d)]({'name':'translation','usage':'maka\x20{generate,\x20g}:translation\x20--lang=<language>','aliases':[a75A(0x1b1)],'shortDesc':a75A(0x17a),'noResource':!![],'examples':[a75A(0x1b9),'maka\x20g:translation\x20--lang=fr','maka\x20g:translation\x20--lang=de'],'validOpts':[a75A(0x18b)]},function(a,b){const B=a75A;try{const c=this['fsi'][B(0x179)](),d=this[B(0x18c)][B(0x19a)](),f=this['fsi'][B(0x183)]();this[B(0x18c)][B(0x1b8)](c,()=>{const C=B;try{!b['lang']&&(b['lang']='en');!b[C(0x18e)]&&!this[C(0x18c)][C(0x195)](C(0x180))&&(Log[C(0x1aa)](C(0x1a5)),this[C(0x18c)][C(0x182)](C(0x192),{'cwd':f}),this[C(0x18c)][C(0x1a8)](C(0x1a7),!![]));const g=this[C(0x18c)]['pathFromApp']({'pathParts':[C(0x1ae),C(0x186),'client',C(0x184)]}),h=this[C(0x18c)][C(0x185)]({'pathParts':[g],'config':c}),i=this['fsi'][C(0x196)](a75e[C(0x19e)](h)[C(0x19b)](),'import\x20\x27../lib/services/translations/i18n\x27;')[0x0]&&!![];if(c['engines'][C(0x1b2)]===C(0x1a9)){!i&&this[C(0x18c)][C(0x18a)]({'filePath':h,'content':C(0x197)});const t=this['fsi'][C(0x1ac)]({'pathParts':[C(0x1ae),C(0x186),C(0x1ba),C(0x184)]}),u=this[C(0x18c)][C(0x185)]({'pathParts':[t],'config':c}),v=this[C(0x18c)][C(0x196)](a75e[C(0x19e)](u)[C(0x19b)](),C(0x17e))[0x0]&&!![];!v&&this['fsi']['injectAtBeginningOfFile']({'filePath':u,'content':C(0x197)});}else!i&&this['fsi'][C(0x18a)]({'filePath':h,'content':'import\x20\x27../lib/services/translations/i18n\x27;\x0a'});const j={'app':d[C(0x199)],'config':c},k=this[C(0x18c)][C(0x1ac)]({'pathParts':[C(0x1ae),C(0x186),C(0x189),C(0x193),C(0x18d),C(0x19c)]}),l=this[C(0x18c)][C(0x181)](this['fsi'][C(0x185)]({'pathParts':[k],'config':c}));!l&&this[C(0x18c)][C(0x190)]({'srcPath':C(0x194),'destPath':k,'framework':C(0x1a3),'context':j,'config':c});const m=this[C(0x18c)][C(0x1ac)]({'pathParts':[C(0x1ae),C(0x186),'lib',C(0x193),C(0x18d),'locales',b[C(0x18b)]+C(0x1b3)]}),n=this['fsi']['rewriteDestinationPathForEngine']({'pathParts':[m],'config':c}),o=this[C(0x18c)][C(0x181)](n);!o?this[C(0x18c)][C(0x190)]({'srcPath':C(0x1af),'destPath':m,'framework':'service','context':j,'config':c}):Log[C(0x1aa)]('Locale\x20already\x20defined:\x20'+n);const p=this[C(0x18c)][C(0x1ac)]({'pathParts':[C(0x1ae),C(0x186),'lib',C(0x193),C(0x18d),C(0x1b7),C(0x18f)+c[C(0x1a2)]['js']]}),q=this['fsi'][C(0x185)]({'pathParts':[p],'config':c}),r=this['fsi']['isFile'](q);!r&&this[C(0x18c)][C(0x190)]({'srcPath':C(0x19d),'destPath':p,'framework':C(0x1a3),'context':j,'config':c});const s=this['fsi'][C(0x196)](a75e[C(0x19e)](p)[C(0x19b)](),'default\x20as\x20'+b[C(0x18b)])[0x0]&&!![];!s?this[C(0x18c)][C(0x1a6)]({'filePath':p,'content':C(0x1a0)+b[C(0x18b)]+'\x20}\x20from\x20\x27./'+b['lang']+'\x27;'}):Log[C(0x1aa)](C(0x191)+p);}catch(w){Log[C(0x198)](w),process[C(0x1b0)](0x1);}});}catch(g){Log[B(0x198)](g),process[B(0x1b0)](0x1);}});
@@ -1,2 +1,2 @@
1
1
  #!/usr/bin/env -S node --experimental-modules --no-warnings --experimental-json-modules
2
- const a76m=a76d;(function(a,b){const j=a76d,c=a();while(!![]){try{const d=-parseInt(j(0x17b))/0x1*(parseInt(j(0x192))/0x2)+parseInt(j(0x18d))/0x3*(parseInt(j(0x179))/0x4)+parseInt(j(0x185))/0x5*(-parseInt(j(0x18c))/0x6)+-parseInt(j(0x182))/0x7+-parseInt(j(0x183))/0x8*(-parseInt(j(0x17e))/0x9)+-parseInt(j(0x17d))/0xa+parseInt(j(0x188))/0xb;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a76c,0xec2a5));const a76b=(function(){let a=!![];return function(b,c){const d=a?function(){const k=a76d;if(c){const e=c[k(0x18e)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a76a=a76b(this,function(){const l=a76d;return a76a[l(0x190)]()[l(0x189)](l(0x18f))['toString']()[l(0x18a)](a76a)[l(0x189)](l(0x18f));});a76a();import a76e from'minimist';import a76f from'os';import a76g from'path';function a76c(){const n=['20BDsPws','stringify','run','29414803mShhYt','search','constructor','floor','571134iXwmjI','90PLmnzo','apply','(((.+)+)+)+$','toString','camelizeKeys','10RidaCG','BROWSERSLIST_IGNORE_OLD_DATA','70928ifXScP','--max-old-space-size=','108268qyqxqI','slice','9578070XXEFiJ','142362zaRXqh','totalmem','dirname','MAKA_COMMAND_PATH','4615373RKfsIU','152EBiVcT','env'];a76c=function(){return n;};return a76c();}import a76h from'humps';import a76i from'./commands/maka.cmd.js';import'./commands/_index.js';import'./generators/_index.js';import{fileURLToPath}from'url';const __filename=fileURLToPath(import.meta['url']),__dirname=a76g[a76m(0x180)](__filename);function a76d(a,b){const c=a76c();return a76d=function(d,e){d=d-0x178;let f=c[d];return f;},a76d(a,b);}global[a76m(0x181)]=__dirname;const total_memory=a76f[a76m(0x17f)](),total_mem_in_kb=total_memory/0x400;let total_mem_in_mb=total_mem_in_kb/0x400;total_mem_in_mb=Math[a76m(0x18b)](total_mem_in_mb),process[a76m(0x184)]['TOOL_NODE_FLAGS']=a76m(0x17a)+total_mem_in_mb,process[a76m(0x184)][a76m(0x178)]='1';const argv=a76e(process['argv'][a76m(0x17c)](0x2)),args=argv['_'],deepCopyArgv=JSON['parse'](JSON[a76m(0x186)](argv));delete deepCopyArgv['_'];const opts=a76h[a76m(0x191)](deepCopyArgv);a76i[a76m(0x187)](args,opts);
2
+ const a76l=a76d;(function(a,b){const j=a76d,c=a();while(!![]){try{const d=parseInt(j(0x1aa))/0x1+-parseInt(j(0x1b4))/0x2+-parseInt(j(0x1b5))/0x3*(parseInt(j(0x1ad))/0x4)+-parseInt(j(0x1ab))/0x5+-parseInt(j(0x1bd))/0x6*(-parseInt(j(0x1a2))/0x7)+parseInt(j(0x1be))/0x8*(-parseInt(j(0x1b2))/0x9)+-parseInt(j(0x1b0))/0xa*(-parseInt(j(0x1a9))/0xb);if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a76c,0xcc4e2));const a76b=(function(){let a=!![];return function(b,c){const d=a?function(){if(c){const e=c['apply'](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a76a=a76b(this,function(){const k=a76d;return a76a[k(0x1a6)]()[k(0x1a5)]('(((.+)+)+)+$')[k(0x1a6)]()[k(0x1a1)](a76a)[k(0x1a5)](k(0x1bb));});function a76d(a,b){const c=a76c();return a76d=function(d,e){d=d-0x1a1;let f=c[d];return f;},a76d(a,b);}a76a();import a76e from'minimist';import a76f from'os';import a76g from'path';function a76c(){const m=['stringify','run','search','toString','argv','TOOL_NODE_FLAGS','451fAsFOf','945895IkPKkL','7830140mfoBDn','BROWSERSLIST_IGNORE_OLD_DATA','4rAUrKr','floor','url','721030WverSB','--max-old-space-size=','9jxkCrx','env','2889920icVhWx','3422046FgoPIs','camelizeKeys','parse','slice','dirname','MAKA_COMMAND_PATH','(((.+)+)+)+$','totalmem','6PBuYcm','2706216BjUiAO','constructor','9972641bSUfBT'];a76c=function(){return m;};return a76c();}import a76h from'humps';import a76i from'./commands/maka.cmd.js';import'./commands/_index.js';import'./generators/_index.js';import{fileURLToPath}from'url';const __filename=fileURLToPath(import.meta[a76l(0x1af)]),__dirname=a76g[a76l(0x1b9)](__filename);global[a76l(0x1ba)]=__dirname;const total_memory=a76f[a76l(0x1bc)](),total_mem_in_kb=total_memory/0x400;let total_mem_in_mb=total_mem_in_kb/0x400;total_mem_in_mb=Math[a76l(0x1ae)](total_mem_in_mb),process[a76l(0x1b3)][a76l(0x1a8)]=a76l(0x1b1)+total_mem_in_mb,process[a76l(0x1b3)][a76l(0x1ac)]='1';const argv=a76e(process[a76l(0x1a7)][a76l(0x1b8)](0x2)),args=argv['_'],deepCopyArgv=JSON[a76l(0x1b7)](JSON[a76l(0x1a3)](argv));delete deepCopyArgv['_'];const opts=a76h[a76l(0x1b6)](deepCopyArgv);a76i[a76l(0x1a4)](args,opts);
@@ -6,12 +6,14 @@ import { browserHistory } from 'react-router';
6
6
  import { withTracker } from 'meteor/react-meteor-data';
7
7
  <% if (config.engines.graphql === 'apollo') { %>
8
8
  // Apollo Client configuration
9
- import { ApolloClient, ApolloProvider } from '@apollo/client';
9
+ import {
10
+ ApolloClient,
11
+ ApolloProvider,
12
+ createHttpLink,
13
+ InMemoryCache
14
+ } from '@apollo/client';
10
15
  import { ApolloProvider as ApolloHooksProvider } from '@apollo/react-hooks';
11
- import { InMemoryCache } from 'apollo-cache-inmemory';
12
- import { ApolloLink } from 'apollo-link';
13
- import { HttpLink, createHttpLink } from 'apollo-link-http';
14
- import { setContext } from "apollo-link-context";
16
+ import { setContext } from "@apollo/link-context";
15
17
 
16
18
  const httpLink = createHttpLink({
17
19
  uri: `/graphql`
@@ -38,14 +40,25 @@ const client = new ApolloClient({
38
40
  });
39
41
  <% } %><% if (config.engines.theme === 'material') { if (config.engines.ssr === 'true') { %>
40
42
  import { ThemeProvider } from '@mui/material/styles';
43
+ import CssBaseline from '@mui/material/CssBaseline';
41
44
  import { theme } from '../lib/index';<% } else { %>
42
45
  // Material UI Theme config using default mui.
43
46
  import { ThemeProvider, createTheme, responsiveFontSizes } from '@mui/material/styles';
47
+ import CssBaseline from '@mui/material/CssBaseline';
44
48
  // https://mui.com/material-ui/customization/default-theme/
45
49
  let theme = createTheme({
46
50
  typography: {
47
51
  useNextVariants: true,
48
52
  },
53
+ components: {
54
+ MuiCssBaseline: {
55
+ styleOverrides: {
56
+ body: {
57
+ backgroundColor: '#fff', // sets default background
58
+ },
59
+ },
60
+ },
61
+ },
49
62
  });
50
63
  theme = responsiveFontSizes(theme);<% }} %>
51
64
  <% if (config.engines.ssr === 'true') { %>
@@ -59,7 +72,8 @@ const App = ({ user }) => (<% if (config.engines.ssr === 'true') { %>
59
72
  <BrowserRouter><% } %><% if (config.engines.graphql === 'apollo') { %>
60
73
  <ApolloProvider client={client}>
61
74
  <ApolloHooksProvider client={client}><% } %><% if (config.engines.theme === 'material') { %>
62
- <ThemeProvider theme={theme}><% } %>
75
+ <ThemeProvider theme={theme}>
76
+ <CssBaseline /><% } %>
63
77
  <Routes user={user} history={browserHistory}/><% if (config.engines.theme === 'material') { %>
64
78
  </ThemeProvider><% } %><% if (config.engines.graphql === 'apollo') { %>
65
79
  </ApolloHooksProvider>
@@ -6,13 +6,14 @@ import { browserHistory } from 'react-router';
6
6
  import { withTracker } from 'meteor/react-meteor-data';
7
7
  <% if (config.engines.graphql === 'apollo') { %>
8
8
  // Apollo Client configuration
9
- import { ApolloClient } from '@apollo/client';
10
- import { ApolloClient, ApolloProvider } from '@apollo/client';
9
+ import {
10
+ ApolloClient,
11
+ ApolloProvider,
12
+ createHttpLink,
13
+ InMemoryCache
14
+ } from '@apollo/client';
11
15
  import { ApolloProvider as ApolloHooksProvider } from '@apollo/react-hooks';
12
- import { InMemoryCache } from 'apollo-cache-inmemory';
13
- import { ApolloLink } from 'apollo-link';
14
- import { HttpLink, createHttpLink } from 'apollo-link-http';
15
- import { setContext } from "apollo-link-context";
16
+ import { setContext } from "@apollo/link-context";
16
17
 
17
18
  const httpLink = createHttpLink({
18
19
  uri: `/graphql`
@@ -39,14 +40,26 @@ const client = new ApolloClient({
39
40
  });
40
41
  <% } %><% if (config.engines.theme === 'material') { if (config.engines.ssr === 'true') { %>
41
42
  import { ThemeProvider } from '@mui/material/styles';
43
+ import CssBaseline from '@mui/material/CssBaseline';
42
44
  import { theme } from '../lib/index';<% } else { %>
43
45
  // Material UI Theme config using default mui.
46
+ // https://mui.com/material-ui/customization/default-theme/
44
47
  import { ThemeProvider, createTheme, responsiveFontSizes } from '@mui/material/styles';
48
+ import CssBaseline from '@mui/material/CssBaseline';
45
49
  // https://mui.com/material-ui/customization/default-theme/
46
50
  let theme = createTheme({
47
51
  typography: {
48
52
  useNextVariants: true,
49
53
  },
54
+ components: {
55
+ MuiCssBaseline: {
56
+ styleOverrides: {
57
+ body: {
58
+ backgroundColor: '#fff', // sets default background
59
+ },
60
+ },
61
+ },
62
+ },
50
63
  });
51
64
  theme = responsiveFontSizes(theme);<% }} %>
52
65
  <% if (config.engines.ssr === 'true') { %>
@@ -60,7 +73,8 @@ const App = ({ user }) => (<% if (config.engines.ssr === 'true') { %>
60
73
  <BrowserRouter><% } %><% if (config.engines.graphql === 'apollo') { %>
61
74
  <ApolloProvider client={client}>
62
75
  <ApolloHooksProvider client={client}><% } %><% if (config.engines.theme === 'material') { %>
63
- <ThemeProvider theme={theme}><% } %>
76
+ <ThemeProvider theme={theme}>
77
+ <CssBaseline /><% } %>
64
78
  <Routes user={user} history={browserHistory}/><% if (config.engines.theme === 'material') { %>
65
79
  </ThemeProvider><% } %><% if (config.engines.graphql === 'apollo') { %>
66
80
  </ApolloHooksProvider>
@@ -1,11 +1,21 @@
1
1
  /** @namespace Common */<% if (config.engines.theme === 'material' && config.engines.ssr === 'true') { %>
2
2
  // Material UI Theme config using roboto typefont and default mui.
3
3
  import { createTheme, responsiveFontSizes } from '@mui/material/styles';
4
+ import CssBaseline from '@mui/material/CssBaseline';
4
5
  // https://mui.com/material-ui/customization/default-theme/
5
6
  let theme = createTheme({
6
7
  typography: {
7
8
  useNextVariants: true,
8
9
  },
10
+ components: {
11
+ MuiCssBaseline: {
12
+ styleOverrides: {
13
+ body: {
14
+ backgroundColor: '#fff', // sets default background
15
+ },
16
+ },
17
+ },
18
+ },
9
19
  });
10
20
  theme = responsiveFontSizes(theme);
11
21
  export { theme };<% } %>
@@ -1,11 +1,21 @@
1
1
  /** @namespace Common */<% if (config.engines.theme === 'material' && config.engines.ssr === 'true') { %>
2
2
  // Material UI Theme config using roboto typefont and default mui.
3
3
  import { createTheme, responsiveFontSizes } from '@mui/material/styles';
4
+ import CssBaseline from '@mui/material/CssBaseline';
4
5
  // https://mui.com/material-ui/customization/default-theme/
5
6
  let theme = createTheme({
6
7
  typography: {
7
8
  useNextVariants: true,
8
9
  },
10
+ components: {
11
+ MuiCssBaseline: {
12
+ styleOverrides: {
13
+ body: {
14
+ backgroundColor: '#fff', // sets default background
15
+ },
16
+ },
17
+ },
18
+ },
9
19
  });
10
20
  theme = responsiveFontSizes(theme);
11
21
  export { theme };<% } %>
@@ -4,17 +4,20 @@ Meteor.startup(() => {
4
4
  WebAppInternals.setInlineScriptsAllowed(false);
5
5
  });
6
6
  <% if (config.engines.graphql === 'apollo') { %>
7
- import { ApolloServer } from 'apollo-server-express';
7
+ import { ApolloServer } from '@apollo/server';
8
8
  import { WebApp } from 'meteor/webapp';
9
9
  import { getUser } from 'meteor/apollo';
10
10
  import { mergeTypeDefs, mergeResolvers } from '@graphql-tools/merge';
11
11
  import {
12
12
  ApolloServerPluginLandingPageGraphQLPlayground
13
- } from "apollo-server-core";
13
+ } from '@apollo/server-plugin-landing-page-graphql-playground';
14
+ import { expressMiddleware } from '@apollo/server/express4';
15
+ import express from 'express';
14
16
 
15
17
  const typeList = [];
16
18
  const resolverList = [];
17
19
  if (typeList.length > 0 && resolverList.length > 0) {
20
+ const expressApp = express();
18
21
  const typeDefs = mergeTypeDefs(typeList);
19
22
  const resolvers = mergeResolvers(resolverList);
20
23
  const server = new ApolloServer({
@@ -24,13 +27,15 @@ if (typeList.length > 0 && resolverList.length > 0) {
24
27
  defaultMaxAge: 60, //seconds
25
28
  },
26
29
  cache: 'bounded',
27
- context: async ({ req }) => ({
28
- user: await getUser(req.headers.authorization) || await getUser(req.headers['x-auth-token']) || {},
29
- }),
30
30
  formatError: (err) => {
31
- // Don't give specific errors to the client
32
- console.error(err);
33
- return err.message ;
31
+ if (Meteor.isProduction === 'production') {
32
+ // Don't give specific errors to the client
33
+ sysLogger.error(err);
34
+ err.message = err.extensions.code; // eslint-disable-line no-param-reassign
35
+ return err;
36
+ }
37
+ console.log(err);
38
+ return err;
34
39
  },
35
40
  plugins: [
36
41
  ApolloServerPluginLandingPageGraphQLPlayground()
@@ -39,12 +44,15 @@ if (typeList.length > 0 && resolverList.length > 0) {
39
44
 
40
45
  const startApolloServer = async(server) => {
41
46
  await server.start();
42
-
43
- server.applyMiddleware({
44
- app: WebApp.connectHandlers,
45
- path: '/graphql',
46
- cors: true
47
- });
47
+ expressApp.use(
48
+ '/graphql',
49
+ expressMiddleware(server, {
50
+ context: async ({ req }) => ({
51
+ user: await getUser(req.headers.authorization) || await getUser(req.headers['x-auth-token']) || {},
52
+ }),
53
+ }),
54
+ );
55
+ WebApp.connectHandlers.use(expressApp);
48
56
  };
49
57
 
50
58
  startApolloServer(server);
@@ -72,6 +80,7 @@ const networkInterface = createMeteorNetworkInterface({
72
80
  const client = new ApolloClient(meteorClientConfig({ networkInterface, ssrMode: true }));<% } %>
73
81
  <% if (config.engines.theme === 'material') { %>
74
82
  import { ThemeProvider } from '@mui/material/styles';
83
+ import CssBaseline from '@mui/material/CssBaseline';
75
84
  import { theme } from '../lib/index';<% } %>
76
85
  // css bundler
77
86
  import createEmotionServer from '@emotion/server/create-instance';
@@ -98,6 +107,7 @@ onPageLoad((sink) => {
98
107
  renderToStringWithData(
99
108
  <ApolloProvider client={client}>
100
109
  <ThemeProvider theme={theme}>
110
+ <CssBaseline />
101
111
  <App location={sink.request.url} />
102
112
  </ThemeProvider>
103
113
  </ApolloProvider>
@@ -110,6 +120,7 @@ onPageLoad((sink) => {
110
120
  });<% } else { %>
111
121
  const html = renderToStaticMarkup(
112
122
  <ThemeProvider theme={theme}>
123
+ <CssBaseline />
113
124
  <App location={sink.request.url} />
114
125
  </ThemeProvider>
115
126
  );
@@ -4,17 +4,20 @@ Meteor.startup(() => {
4
4
  WebAppInternals.setInlineScriptsAllowed(false);
5
5
  });
6
6
  <% if (config.engines.graphql === 'apollo') { %>
7
- import { ApolloServer } from 'apollo-server-express';
7
+ import { ApolloServer } from '@apollo/server';
8
8
  import { WebApp } from 'meteor/webapp';
9
9
  import { getUser } from 'meteor/apollo';
10
10
  import { mergeTypeDefs, mergeResolvers } from '@graphql-tools/merge';
11
11
  import {
12
12
  ApolloServerPluginLandingPageGraphQLPlayground
13
- } from "apollo-server-core";
13
+ } from '@apollo/server-plugin-landing-page-graphql-playground';
14
+ import { expressMiddleware } from '@apollo/server/express4';
15
+ import express from 'express';
14
16
 
15
17
  const typeList = [];
16
18
  const resolverList = [];
17
19
  if (typeList.length > 0 && resolverList.length > 0) {
20
+ const expressApp = express();
18
21
  const typeDefs = mergeTypeDefs(typeList);
19
22
  const resolvers = mergeResolvers(resolverList);
20
23
  const server = new ApolloServer({
@@ -24,12 +27,15 @@ if (typeList.length > 0 && resolverList.length > 0) {
24
27
  defaultMaxAge: 60, //seconds
25
28
  },
26
29
  cache: 'bounded',
27
- context: async ({ req }) => ({
28
- user: await getUser(req.headers.authorization) || await getUser(req.headers['x-auth-token']) || {},
29
- }),
30
30
  formatError: (err) => {
31
- // Don't give specific errors to the client
32
- return err.message;
31
+ if (Meteor.isProduction === 'production') {
32
+ // Don't give specific errors to the client
33
+ sysLogger.error(err);
34
+ err.message = err.extensions.code; // eslint-disable-line no-param-reassign
35
+ return err;
36
+ }
37
+ console.log(err);
38
+ return err;
33
39
  },
34
40
  plugins: [
35
41
  ApolloServerPluginLandingPageGraphQLPlayground()
@@ -38,12 +44,15 @@ if (typeList.length > 0 && resolverList.length > 0) {
38
44
 
39
45
  const startApolloServer = async(server) => {
40
46
  await server.start();
41
-
42
- server.applyMiddleware({
43
- app: WebApp.connectHandlers,
44
- path: '/graphql',
45
- cors: true
46
- });
47
+ expressApp.use(
48
+ '/graphql',
49
+ expressMiddleware(server, {
50
+ context: async ({ req }) => ({
51
+ user: await getUser(req.headers.authorization) || await getUser(req.headers['x-auth-token']) || {},
52
+ }),
53
+ }),
54
+ );
55
+ WebApp.connectHandlers.use(expressApp);
47
56
  };
48
57
 
49
58
  startApolloServer(server);
@@ -71,6 +80,7 @@ const networkInterface = createMeteorNetworkInterface({
71
80
  const client = new ApolloClient(meteorClientConfig({ networkInterface, ssrMode: true }));<% } %>
72
81
  <% if (config.engines.theme === 'material') { %>
73
82
  import { ThemeProvider } from '@mui/material/styles';
83
+ import CssBaseline from '@mui/material/CssBaseline';
74
84
  import { theme } from '../lib/index';<% } %>
75
85
  // css bundler
76
86
  import createEmotionServer from '@emotion/server/create-instance';
@@ -97,6 +107,7 @@ onPageLoad((sink) => {
97
107
  renderToStringWithData(
98
108
  <ApolloProvider client={client}>
99
109
  <ThemeProvider theme={theme}>
110
+ <CssBaseline />
100
111
  <App location={sink.request.url} />
101
112
  </ThemeProvider>
102
113
  </ApolloProvider>
@@ -109,6 +120,7 @@ onPageLoad((sink) => {
109
120
  });<% } else { %>
110
121
  const html = renderToStaticMarkup(
111
122
  <ThemeProvider theme={theme}>
123
+ <CssBaseline />
112
124
  <App location={sink.request.url} />
113
125
  </ThemeProvider>
114
126
  );
@@ -10,7 +10,7 @@ import { gql } from '@apollo/client';
10
10
  // https://www.apollographql.com/docs/react/api/react/hoc/#graphqlquery-configcomponent
11
11
  import { graphql } from '@apollo/client/react/hoc';<% } %><% if (theme === 'material' ) { %>
12
12
  // https://material-ui.com/styles/basics/#higher-order-component-api
13
- import { withStyles } from '@mui/styles';
13
+ import { withStyles } from '@mui/system';
14
14
 
15
15
  const styles = (theme) => { };<% } %>
16
16
  <% if (!isStore) { %>
@@ -10,7 +10,7 @@ import { gql } from '@apollo/client';
10
10
  // https://www.apollographql.com/docs/react/api/react/hoc/#graphqlquery-configcomponent
11
11
  import { graphql } from '@apollo/client/react/hoc';<% } %><% if (theme === 'material' ) { %>
12
12
  // https://material-ui.com/styles/basics/#higher-order-component-api
13
- import { withStyles } from '@mui/styles';
13
+ import { withStyles } from '@mui/system';
14
14
 
15
15
  const styles = (theme) => { };<% } %>
16
16
  <% if (!isStore && client === 'react') { %>
@@ -4,10 +4,7 @@ import React, { Component } from 'react';
4
4
  import { withTracker } from 'meteor/react-meteor-data';<% if(graphql === 'apollo') { %>
5
5
  import { gql } from '@apollo/client';
6
6
  // https://www.apollographql.com/docs/react/api/react/hoc/#graphqlquery-configcomponent
7
- import { graphql } from '@apollo/client/react/hoc';<% } %><% if (theme === 'material' ) { %>
8
- // https://material-ui.com/styles/basics/#higher-order-component-api
9
- import { withStyles } from '@mui/styles';
10
- const styles = (theme) => { };<% } %><% if (withTranslations) { %>
7
+ import { graphql } from '@apollo/client/react/hoc';<% } %><% if (withTranslations) { %>
11
8
  import { withTranslation } from 'react-i18next';<% } %>
12
9
 
13
10
  class <%= className %>Component extends Component {
@@ -59,8 +56,7 @@ class <%= className %>Component extends Component {
59
56
 
60
57
  const <%= className %> = compose(
61
58
  withTracker(() => {}),<% if(graphql === 'apollo') { %>
62
- //graphql(gql`query Todos { todos }`, { variables: {/* input */} }),<% } %><% if(theme === 'material') { %>
63
- withStyles(styles),<% } %><% if (withTranslations) { %>
59
+ //graphql(gql`query Todos { todos }`, { variables: {/* input */} }),<% } %><% if (withTranslations) { %>
64
60
  withTranslation(),<% } %>
65
61
  )(<%= className %>Component);
66
62
 
@@ -4,10 +4,7 @@ import * as PropTypes from 'prop-types';// https://github.com/meteor/react-packa
4
4
  import { withTracker } from 'meteor/react-meteor-data';<% if(graphql === 'apollo') { %>
5
5
  import { gql } from '@apollo/client';
6
6
  // https://www.apollographql.com/docs/react/api/react/hoc/#graphqlquery-configcomponent
7
- import { graphql } from '@apollo/client/react/hoc';<% } %><% if (theme === 'material' ) { %>
8
- // https://material-ui.com/styles/basics/#higher-order-component-api
9
- import { withStyles } from '@mui/styles';
10
- const styles = (theme) => { };<% } %><% if (withTranslations) { %>
7
+ import { graphql } from '@apollo/client/react/hoc';<% } %><% if (withTranslations) { %>
11
8
  import { withTranslation } from 'react-i18next';<% } %>
12
9
 
13
10
  interface I<%= className %> {
@@ -64,8 +61,7 @@ class <%= className %>Component extends React.Component<I<%= className %>> {
64
61
 
65
62
  const <%= className %> = compose(
66
63
  withTracker(() => {}),<% if(graphql === 'apollo') { %>
67
- //graphql(gql`query Todos { todos }`, { variables: {/* input */} }),<% } %><% if(theme === 'material') { %>
68
- withStyles(styles),<% } %><% if (withTranslations) { %>
64
+ //graphql(gql`query Todos { todos }`, { variables: {/* input */} }),<% } %><% if (withTranslations) { %>
69
65
  withTranslation(),<% } %>
70
66
  )(<%= className %>Component);
71
67
 
@@ -2,10 +2,7 @@ import React, { useState } from 'react';
2
2
  // https://github.com/meteor/react-packages/tree/master/packages/react-meteor-data#usetrackerreactivefn-deps-hook
3
3
  import { useTracker } from 'meteor/react-meteor-data';<% if(graphql === 'apollo') { %>
4
4
  // https://www.apollographql.com/docs/react/api/react/hooks/#example-2
5
- import { useQuery, gql } from '@apollo/client';<% } %><% if (theme === 'material' ) { %>
6
- // https://material-ui.com/styles/basics/#higher-order-component-api
7
- import { makeStyles } from '@mui/styles';
8
- const useStyles = makeStyles((theme) => ({}));<% } %><%if (withTranslations) { %>
5
+ import { useQuery, gql } from '@apollo/client';<% } %><%if (withTranslations) { %>
9
6
  import { useTranslation } from 'react-i18next';<% } %>
10
7
 
11
8
 
@@ -15,7 +12,6 @@ function <%= className %>(props) {
15
12
  return { userId }
16
13
  });*/<% if(graphql === 'apollo') { %>
17
14
  //const { loading, error, data } = useQuery(gql`query Todos { todos }`, { variables: {/* input */} }); <% } %><% if (theme === 'material') { %>
18
- const classes = useStyles();<% } %><% if (withTranslations) { %>
19
15
  const { t } = useTranslation();<% } %>
20
16
 
21
17
  return (