🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more

github.com/zrcoder/gfront

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

github.com/zrcoder/gfront

v0.0.0-20220209034004-e0564397d7e0
Version published
Created

gfront

Thanks to Webassybly technology, we can develop front-end in Go+ language now.

Inspired of React, go-app and Go+ classfile

Hello, world

JS(React)

index.html

<!DOCTYPE html>
<html>
  <head>
    <script src="https://unpkg.com/react@16/umd/react.development.js"></script>
    <script src="https://unpkg.com/react-dom@16/umd/react-dom.development.js"></script>
    <script src="https://unpkg.com/babel-standalone@6.26.0/babel.js"></script>
  </head>

  <body>
    <div id="root"></div>
    <script type="text/babel">
      class App extends React.Component {
        render() {
          // JSX:
          return <h1>Hello world!</h1>
          // return React.createElement('h1', 'Hello, React!')
        }
      }
      ReactDOM.render(<App />, document.getElementById('root'))
    </script>
  </body>
</html>

Go+(gfront)

Main.app

route "/", &Hello{}
runWhenOnBrowser

Hello.com

func Render() UI {
    return h1.text("Hello World!")
}

FAQs

Package last updated on 09 Feb 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts