What are some of your challenges developing projects with Go?

polaris · · 417 次点击    
这是一个分享于 的资源,其中的信息可能已经有所发展或是发生改变。
<p>I&#39;m leaving this as an open ended question.</p> <p>Bear in mind, that it doesn&#39;t need to apply to Go, for example: I am irked by various React/Vue/Angular templates, which should be API driven, just provide data for rendering directly inside the .vue/js files. So instead of just implementing some API endpoints, I am often dealing with actually implementing the ajax request logic on the front-end as well. Mostly it&#39;s annoying in very common functionality like login/registration forms, obviously there&#39;s going to be custom work after that.</p> <p>What are some of your pet peeves/challenges that annoy you?</p> <hr/>**评论:**<br/><br/>dillonerhardt: <pre><p>I find templating to be a bit of a pain to set up a good structure for using layouts and reusing elements</p></pre>titpetric: <pre><p>Do you have any obstacles in using an API driven front-end like Vue.js/Angular/React? What would you need to consider using one? (a few articles on how to set it up? an example project? somebody who&#39;ll tell you how to avoid some gotcha&#39;s?)</p></pre>dillonerhardt: <pre><p>I am in the middle of a project using ReactJS with a API in Golang. So far I&#39;m very happy with the choice of technologies. It is a full single page application so the only interactions between the two are the API calls, just simply passing JSON. The API was quick to write only having a few endpoints to start with, so the main development has been in creating the views and handling the calls on the front-end. There is a good video tutorial on &#39;react single page applications with golang&#39; I can&#39;t seem to find it right now though. If you&#39;re gonna go with react I would definitely recommend looking at create-react-app it will help get your dev environment set up and configured with everything you need really fast. As for the go API the only thing that I took some time to figure out was what type of authentication to use. I settled for using JWT middleware wrapped around certain endpoints to manage users.</p></pre>titpetric: <pre><p>Regarding the authentication endpoints and user management - did you consider using some external service like auth0, or some project which would get you half of the way there (ie, where you would just implement the user storage back-end interface?).</p></pre>

入群交流(和以上内容无关):加入Go大咖交流群,或添加微信:liuxiaoyan-s 备注:入群;或加QQ群:692541889

417 次点击  
加入收藏 微博
0 回复
暂无回复
添加一条新回复 (您需要 登录 后才能回复 没有账号 ?)
  • 请尽量让自己的回复能够对别人有帮助
  • 支持 Markdown 格式, **粗体**、~~删除线~~、`单行代码`
  • 支持 @ 本站用户;支持表情(输入 : 提示),见 Emoji cheat sheet
  • 图片支持拖拽、截图粘贴等方式上传