Coding With Fun
Home Docker Django Node.js Articles Python pip guide FAQ Policy

Atom save and preview features


May 24, 2021 Atom


Table of contents


Save and preview features

After using Atom is not found, each time you open the working directory, save exit and reopen the software, the directory is blank. Sublime and DW's shortcut preview html features are not liked, while Atom does not.

Remember the last open directory

This feature, as of the latest version of 0.198, is still in place, and here we implement it with a plug-in, but officially, the "Remember the last open directory" feature has been built into the next version (integrated plug-in), which is also stated by the author of the official version 1.0 plug-in, see this paragraph: The Atom.io team iss isserly building a version of this core for 1.0! https://github.com/atom/atom/issues/1603

Plug-in open-last-project

Plug-in introduction: Atom.io package that automatically repoens the last project and files you work on.

Once installed, the memory function is implemented. Without too many settings, the first time you load a working directory, do you exit opening normally or automatically load the modified directory, and the files you are editing remain edited as well.

Browser preview

For front-end development, browser preview functionality must have wood. Otherwise every time you have to manually drag files to the browser is more troublesome.

Plug-in: RIB - run in browser

Plug-in introduction: Run in Browser will open the current pane in the default web browser

The default usage, look below

  • Command Palette: rib - Command panel search rip
  • Keymap: ctrl s alt s r - default shortcut (conflicts with some of my installed plug-ins and I'm not used to so many keystrokes that I called directly F12)
  • The current pane must be .html or .htm file - the plug-in is currently supported in html and htm suffixes

Personal RIB custom key modifications - for informational purposes only

'atom-text-editor':
  'f12':'rib:run-in-browser'
  'ctrl-shift-space':'autocomplete:toggle'

Tip: Plug-in installation

  1. Set internal search installation
  2. On the Github download plug-in, put the package under the atom directory, reopen the open software will automatically recognize
  3. Install with the apm command, for example: apm install run-in-browser