This is the home of the Go Explorer.
Go Explorer allows you to learn, explore and experiment with the Go Programming language without no setups and needing to install the actual compiler.
Below is listed all the currently available features:
- A clear and user-friendly UI with VS Code like experience including a syntax highlighting.
- You can run, build or test your code with a chosen flags including a few environment variables.
- You can be format goimports and statically analyze go vet your code.
- Error highlighting is supported directly in the code in case your code fails to build or the static analyzer founds some error.
- You can share your code with your friends by a link.
- Tabs are available if you like to experiment different codes at the same time.
- Basic statistics are provided after an execution: build time, binary size and execution time.
- You can import your own code from your local computer.
- Several code templates are available to you if you need something to start with, including: basic, testing, benchmarking, concurrency and generics.
- The most recently edited code is always kept in the local store if in case you accidentally close your session or a browser crashes.
- Currently available versions are: 1.16, 1.17 and 1.18-rc (generics!)
Language: Typescript
The frontend is build using React and the backend server is build using NodeJS and Express .(perhaps in the future backend will be migrated to Go??)
Go source code is executed inside a Docker container to properly isolate the execution. Nginx is used as a load balancer and a reverse proxy for the application.
No network connection is completely disabled on a container. Therefore, access to the outside world is blocked.
The available CPU resources a container can use is limited.
The total compilation and execution time is limited by the container.
cd go-explorer/frontend && npm install
cd go-explorer/backend && npm install
cd go-explorer/frontend
npm run start:dev
This will start a development server allowing a hot reload.
cd go-explorer/backend
npm run start:dev
git pull golang:1.1(6/7/8-rc)
You can configure environment variables placing the .env file to the root of go-explorer/frontend and go-explorer/backend folders.
ENV | NEEDED | DEFAULT | REMARK |
---|---|---|---|
GOLANG_VERSIONS | NO | 1.17 | semicolon separated list of available versions |
PORT | NO | 5000 |
ENV | NEEDED | DEFAULT | REMARK |
---|---|---|---|
GOLANG_VERSIONS | NO | 1.17 | semicolon separated list of available versions |
PORT | NO | 3000 | |
API_BASE_URL | NO | http://localhost:5000/api | |
BASE_URL | NO | http://localhost:3000 |
Run backend tests:
npm run test
Run frontend e2e tests:
npm run test:e2e
- Please share your ideas if the application is missing some feature or there's some issue.
- Suggestions are also welcome if out environment is lacking some Go package.
🙏
The application should work on a relatively modern browser. It has been tested with Firefox (95), Chrome (96), and Edge (96).