2022-11-03 19:33:02 +03:00
|
|
|
//go:build js || aix
|
|
|
|
// +build js aix
|
2021-04-22 12:35:02 +03:00
|
|
|
|
|
|
|
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")
|
|
|
|
}
|