code: func New(filename string, dataCallback func([]byte) error, errorCallback func(error)) (*Reloader, error) {
  	if errorCallback == nil {
  		errorCallback = func(e error) {}
  	}
  	fileInfo, err := os.Stat(filename)
  	if err != nil {
  		return nil, err
  	}
  	b, err := readFile(filename)
  	if err != nil {
  		return nil, err
  	}
  	stopChan := make(chan struct{})
  	tickerStop, tickChan := makeTicker()
  	loop := func() {
  		for {
  			select {
  			case <-stopChan:
  				tickerStop()
  				return
  			case <-tickChan:
  				currentFileInfo, err := os.Stat(filename)
  				if err != nil {
  					errorCallback(err)
  					continue
  				}
  				if !currentFileInfo.ModTime().After(fileInfo.ModTime()) {
  					continue
  				}
  				b, err := readFile(filename)
  				if err != nil {
  					errorCallback(err)
  					continue
  				}
  				fileInfo = currentFileInfo
  				err = dataCallback(b)
  				if err != nil {
  					errorCallback(err)
  				}
  			}
  		}
  	}
  	err = dataCallback(b)
  	if err != nil {
  		tickerStop()
  		return nil, err
  	}
  	go loop()
  	return &Reloader{stopChan}, nil
  }
docs: // New loads the filename provided, and calls the callback.  It then spawns a
  // goroutine to check for updates to that file, calling the callback again with
  // any new contents. The first load, and the first call to callback, are run
  // synchronously, so it is easy for the caller to check for errors and fail
  // fast. New will return an error if it occurs on the first load. Otherwise all
  // errors are sent to the callback.