This is a plugin.

Editor Plugin is just a bridge between Iris and alm-tools.

alm-tools is a typescript online IDE/Editor, made by @basarat one of the top contributors of the Typescript language.

Iris gives you the opportunity to edit your client-side using the alm-tools editor, via the editor plugin.

This plugin starts it's own server. If Iris server is using TLS then the editor will use the same key and cert.

How to use

package main

import (

func main(){
    e := editor.New() 
    // editor.Config{ Username: "admin", Password: "admin!123", Port: 4444, WorkingDir: "/public/scripts"}


    iris.Get("/", func (ctx *iris.Context){})


Note for username, password: The Authorization specifies the authentication mechanism (in this case Basic) followed by the username and password. Although the string aHR0cHdhdGNoOmY= may look encrypted it is simply a base64 encoded version of username:password. Would be readable to anyone who could intercept the HTTP request (if TLS is not used). Read more here.

The editor can't work if the directory doesn't contain a tsconfig.json.

If you are using the typescript plugin you don't have to call the .Dir(...)

results matching ""

    No results matching ""