diff --git a/.git-blame-ignore-revs b/.git-blame-ignore-revs
new file mode 100644
index 00000000..47b9ddba
--- /dev/null
+++ b/.git-blame-ignore-revs
@@ -0,0 +1 @@
+# Add prettier to the project
diff --git a/.prettierignore b/.prettierignore
new file mode 100644
index 00000000..595b4cc1
--- /dev/null
+++ b/.prettierignore
@@ -0,0 +1,14 @@
+node_modules
+src
+deps
+.clang-format
+
+# Minified files
+**/*.min.css
+**/*.min.js
+**/leaflet.*
+**/commonmark*
+**/w3.css
+apps/ssb/tribute.esm.js
+apps/api/app.js
+**/emojis.json
diff --git a/.prettierrc.yaml b/.prettierrc.yaml
new file mode 100644
index 00000000..1f7ef42f
--- /dev/null
+++ b/.prettierrc.yaml
@@ -0,0 +1,10 @@
+trailingComma: 'es5'
+useTabs: true
+semi: true
+singleQuote: true
+bracketSpacing: false
+# overrides:
+# - files: '**/*.json'
+# options:
+# useTabs: false
+# tabWidth: 2
diff --git a/README.md b/README.md
index b7c474a2..c6073dc5 100644
--- a/README.md
+++ b/README.md
@@ -1,43 +1,37 @@
# Tilde Friends
+
Tilde Friends is a tool for making and sharing.
A public instance lives at https://www.tildefriends.net/.
-It is both a peer-to-peer social network client, participating in Secure
-Scuttlebutt, as well as a platform for writing and running web applications.
+It is both a peer-to-peer social network client, participating in Secure Scuttlebutt, as well as a platform for writing and running web applications.
## Goals
+
1. Make it easy and fun to run all sorts of web applications.
2. Provide security that is easy to understand and protects your data.
-3. Make creating and sharing web applications accessible to anyone with a
- browser.
+3. Make creating and sharing web applications accessible to anyone with a browser.
## Building
-Builds on Linux (x86_64 and aarch64), MacOS, OpenBSD, and Haiku. Builds for
-all of those host platforms plus mingw64, iOS, and android.
-1. Requires openssl (`libssl-dev`, in debian-speak). All other dependencies
- are kept up to date in the tree.
-2. To build, run `make debug` or `make release`. An executable will be
- generated in a subdirectory of `out/`.
-3. It's possible to build for Android, iOS, and Windows on Linux, if you have
- the right dependencies in the right places. `make windebug winrelease
- iosdebug-ipa iosrelease-ipa release-apk`.
+Builds on Linux (x86_64 and aarch64), MacOS, OpenBSD, and Haiku. Builds for all of those host platforms plus mingw64, iOS, and android.
+
+1. Requires openssl (`libssl-dev`, in debian-speak). All other dependencies are kept up to date in the tree.
+2. To build, run `make debug` or `make release`. An executable will be generated in a subdirectory of `out/`.
+3. It's possible to build for Android, iOS, and Windows on Linux, if you have the right dependencies in the right places. `make windebug winrelease iosdebug-ipa iosrelease-ipa release-apk`.
4. To build in docker, `docker build .`.
5. `make format` will normalize formatting to the coding standard.
## Running
-By default, running the built `tildefriends` executable will start a web server
-at . `tildefriends -h` lists further options.
-The first user to create an account and log in will be granted administrative
-privileges. Further administration can be done at
-.
+By default, running the built `tildefriends` executable will start a web server at . `tildefriends -h` lists further options.
+
+The first user to create an account and log in will be granted administrative privileges. Further administration can be done at .
## Documentation
-Docs are a work in progress:
-.
+
+Docs are a work in progress: .
## License
-All code unless otherwise noted in is provided under the
-[MIT](https://opensource.org/licenses/MIT) license.
+
+All code unless otherwise noted in is provided under the [MIT](https://opensource.org/licenses/MIT) license.
diff --git a/apps/admin.json b/apps/admin.json
index 711779a2..a9a2e723 100644
--- a/apps/admin.json
+++ b/apps/admin.json
@@ -1,4 +1,4 @@
{
- "type": "tildefriends-app",
- "emoji": "🎛"
-}
\ No newline at end of file
+ "type": "tildefriends-app",
+ "emoji": "🎛"
+}
diff --git a/apps/admin/app.js b/apps/admin/app.js
index 0a1c35e8..5916f11f 100644
--- a/apps/admin/app.js
+++ b/apps/admin/app.js
@@ -18,9 +18,13 @@ async function main() {
for (let user of await core.users()) {
data.users[user] = await core.permissionsForUser(user);
}
- await app.setDocument(utf8Decode(getFile('index.html')).replace('$data', JSON.stringify(data)));
+ await app.setDocument(
+ utf8Decode(getFile('index.html')).replace('$data', JSON.stringify(data))
+ );
} catch {
- await app.setDocument('Only an administrator can modify these settings.');
+ await app.setDocument(
+ 'Only an administrator can modify these settings.'
+ );
}
}
-main();
\ No newline at end of file
+main();
diff --git a/apps/admin/index.html b/apps/admin/index.html
index eabbf708..114ab1b9 100644
--- a/apps/admin/index.html
+++ b/apps/admin/index.html
@@ -1,10 +1,12 @@
-
+
-
+
Tilde Friends Administration
-
\ No newline at end of file
+