Skip to content

Commit 1a7fded

Browse files
committed
[prettier] add files to ignore & run prettier
1 parent 6b2e613 commit 1a7fded

File tree

2 files changed

+17
-4
lines changed

2 files changed

+17
-4
lines changed

.prettierignore

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
package.json
2+
extension.yaml
3+
webpack.config.js
4+
**/node_modules/**
5+
6+
# generated files
7+
README.md
8+
POSTINSTALL.md
9+
PREINSTALL.md
10+
**/functions/lib/**
11+
**/dist/**

firestore-counter/CONTRIBUTING.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
**DESCRIPTION**: Auto-scalable counters for your app.
44

5-
65
**FEATURES**:
76

87
- Zero configuration, one mod for all your app needs
@@ -13,24 +12,26 @@
1312
- Works well offline and provides latency compensation
1413
- Counter updates are immediately visible locally even though the main counter is eventually updated
1514

16-
1715
**DETAILS**: This mod allows you to increment any fields in your documents at arbitrary rate.
1816

1917
Client SDK, instead of incrementing the field directly, increments their own shard in `_counter_shards_` subcollection. A background task is periodically aggregating these shards and eventually rolling them up to the main counters.
2018

2119
There are three cloud functions that orchestrate shard aggregations:
22-
1. A `worker` function is responsible for monitoring and aggregating a range of shards. There may be 0 or hundreds of workers running concurrently to scale up to large workloads
20+
21+
1. A `worker` function is responsible for monitoring and aggregating a range of shards. There may be 0 or hundreds of workers running concurrently to scale up to large workloads
2322
2. A `controller` function runs every minute and monitors the health of the workers. It can scale up and down the number of workers as needed and recover a worker on failure.
2423
3. A `onWrite` function triggers every time a shard is written and runs one-time aggregation. This improves latency for low workloads where no workers is running. To improve efficiency there's only one instance of this function running at any given time (`maxInstances` is set to 1).
2524

2625
# Installation
26+
2727
```
2828
firebase mods:install . --project=<my-project-id>
2929
3030
Please check the post-install message for the final step to set up your mod.
3131
```
3232

3333
# Web SDK
34+
3435
```
3536
<html>
3637
<head>
@@ -47,7 +48,7 @@ Please check the post-install message for the final step to set up your mod.
4748
4849
// Initialize the sharded counter.
4950
var views = new sharded.Counter(db.doc("pages/hello-world"), "stats.views");
50-
51+
5152
// This will increment a field "stats.views" of the "pages/hello-world" document by 3.
5253
views.incrementBy(3);
5354
@@ -66,6 +67,7 @@ Please check the post-install message for the final step to set up your mod.
6667
```
6768

6869
# Building from source
70+
6971
```
7072
cd functions/
7173
npm install

0 commit comments

Comments
 (0)