repl.txt (1040B)
1 2 {{alias}}( [p] ) 3 Returns a directory for user-specific configuration files. 4 5 On Windows platforms, the function first checks for a `LOCALAPPDATA` 6 environment variable before checking for an `APPDATA` environment variable. 7 This means that machine specific user configuration files have precedence 8 over roaming user configuration files. 9 10 On non-Windows platforms, if the function is unable to locate the current 11 user's `home` directory, the function returns `null`. Similarly, on Windows 12 platforms, if the function is unable to locate an application data 13 directory, the function also returns `null`. 14 15 Parameters 16 ---------- 17 p: string (optional) 18 Path to append to a base directory. 19 20 Returns 21 ------- 22 out: string|null 23 Directory. 24 25 Examples 26 -------- 27 > var dir = {{alias}}() 28 e.g., '/Users/<username>/Library/Preferences' 29 > dir = {{alias}}( 'appname/config' ) 30 e.g., '/Users/<username>/Library/Preferences/appname/config' 31 32 See Also 33 -------- 34