Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x/tools/gopls: Issue installing GopherJS package #45561

Open
Cbonnin88 opened this issue Apr 14, 2021 · 2 comments
Open

x/tools/gopls: Issue installing GopherJS package #45561

Cbonnin88 opened this issue Apr 14, 2021 · 2 comments

Comments

@Cbonnin88
Copy link

@Cbonnin88 Cbonnin88 commented Apr 14, 2021

What version of Go are you using (go version)?

$ go version
1.16.3

Does this issue reproduce with the latest release?

Yes

What operating system and processor architecture are you using (go env)?

Windows

go env Output
$ go env

What did you do?

I am trying to install a GopherJS package

package main

import (
	"fmt"

	"syscall/js"
)

func main() {
	fmt.Println("Hello Go !")
	js.Global.Get("document").Call("alert", "Hello JavaScript!")
	println("Yo JavaScript console")

}

What did you expect to see?

Hello Go inside of the compiler
hello JavaScript inside of the an JavaScript alert window
Yo JavaScript inside the web console

What did you see instead?

Error loading workspace: You are outside of a module and outside of $GOPATH/src. If you are using modules, please open your editor to a directory in your module. If you believe this warning is incorrect, please file an issue: https://github.com/golang/go/issues/new.

@seankhliao
Copy link
Contributor

@seankhliao seankhliao commented Apr 14, 2021

please provide the output of go env

@seankhliao seankhliao changed the title Issue installing GopherJS package x/tools/gopls: Issue installing GopherJS package Apr 14, 2021
@gopherbot gopherbot added this to the Unreleased milestone Apr 14, 2021
@heschi heschi modified the milestones: Unreleased, Backlog Apr 16, 2021
@stamblerre stamblerre modified the milestones: Backlog, gopls/unplanned Apr 27, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
5 participants