code: def serve(self, port=5500, liveport=None, host=None, root=None, debug=None,
                open_url=False, restart_delay=2, open_url_delay=None,
                live_css=True):
          
          host = host or '127.0.0.1'
          if root is not None:
              self.root = root
  
          self._setup_logging()
          logger.info('Serving on http://%s:%s' % (host, port))
  
          self.application(
              port, host, liveport=liveport, debug=debug, live_css=live_css)
  
          # Async open web browser after 5 sec timeout
          if open_url or open_url_delay:
              if open_url:
                  logger.warn('Use `open_url_delay` instead of `open_url`')
              sleep = open_url_delay or 5
  
              def opener():
                  time.sleep(sleep)
                  webbrowser.open('http://%s:%s' % (host, port))
              threading.Thread(target=opener).start()
  
          try:
              self.watcher._changes.append(('__livereload__', restart_delay))
              LiveReloadHandler.start_tasks()
              add_reload_hook(lambda: IOLoop.instance().close(all_fds=True))
              IOLoop.instance().start()
          except KeyboardInterrupt:
              logger.info('Shutting down...')
docs: Start serve the server with the given port.
  
          :param port: serve on this port, default is 5500
          :param liveport: live reload on this port
          :param host: serve on this hostname, default is 127.0.0.1
          :param root: serve static on this root directory
          :param debug: set debug mode, which autoreloads the app on code changes
                        via Tornado (and causes polling). Defaults to True when
                        ``self.app`` is set, otherwise False.
          :param open_url_delay: open webbrowser after the delay seconds
          :param live_css: whether to use live css or force reload on css.
                           Defaults to True