summaryrefslogtreecommitdiffstats
path: root/vendor/github.com/spf13/viper/watch_wasm.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/spf13/viper/watch_wasm.go')
-rw-r--r--vendor/github.com/spf13/viper/watch_wasm.go30
1 files changed, 30 insertions, 0 deletions
diff --git a/vendor/github.com/spf13/viper/watch_wasm.go b/vendor/github.com/spf13/viper/watch_wasm.go
new file mode 100644
index 00000000..8e47e6a9
--- /dev/null
+++ b/vendor/github.com/spf13/viper/watch_wasm.go
@@ -0,0 +1,30 @@
+// +build js,wasm
+
+package viper
+
+import (
+ "errors"
+
+ "github.com/fsnotify/fsnotify"
+)
+
+type watcher struct {
+ Events chan fsnotify.Event
+ Errors chan error
+}
+
+func (*watcher) Close() error {
+ return nil
+}
+
+func (*watcher) Add(name string) error {
+ return nil
+}
+
+func (*watcher) Remove(name string) error {
+ return nil
+}
+
+func newWatcher() (*watcher, error) {
+ return &watcher{}, errors.New("fsnotify is not supported on WASM")
+}