-
Notifications
You must be signed in to change notification settings - Fork 900
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
122 additions
and
167 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,7 @@ | ||
{ | ||
"name": "@firebase/database-compat/standalone", | ||
"description": "The entry point for sharing code with Admin SDK", | ||
"main": "../dist/index.standalone.js", | ||
"typings": "../dist/database-compat/src/index.standalone.d.ts", | ||
"private": true | ||
} | ||
|
||
"name": "@firebase/database-compat/standalone", | ||
"description": "The entry point for sharing code with Admin SDK", | ||
"main": "../dist/index.standalone.js", | ||
"typings": "../dist/database-compat/src/index.standalone.d.ts", | ||
"private": true | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,96 @@ | ||
/** | ||
* @license | ||
* Copyright 2021 Google LLC | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
// APIs that don't depend on @firebase/app | ||
export { | ||
Database, | ||
EmulatorMockTokenOptions, | ||
enableLogging, | ||
goOffline, | ||
goOnline, | ||
connectDatabaseEmulator | ||
} from './api/Database'; | ||
export { | ||
Query, | ||
DatabaseReference, | ||
ListenOptions, | ||
Unsubscribe, | ||
ThenableReference | ||
} from './api/Reference'; | ||
export { OnDisconnect } from './api/OnDisconnect'; | ||
export { | ||
DataSnapshot, | ||
EventType, | ||
QueryConstraint, | ||
QueryConstraintType, | ||
endAt, | ||
endBefore, | ||
equalTo, | ||
get, | ||
limitToFirst, | ||
limitToLast, | ||
off, | ||
onChildAdded, | ||
onChildChanged, | ||
onChildMoved, | ||
onChildRemoved, | ||
onDisconnect, | ||
onValue, | ||
orderByChild, | ||
orderByKey, | ||
orderByPriority, | ||
orderByValue, | ||
push, | ||
query, | ||
ref, | ||
refFromURL, | ||
remove, | ||
set, | ||
setPriority, | ||
setWithPriority, | ||
startAfter, | ||
startAt, | ||
update, | ||
child | ||
} from './api/Reference_impl'; | ||
export { increment, serverTimestamp } from './api/ServerValue'; | ||
export { | ||
runTransaction, | ||
TransactionOptions, | ||
TransactionResult | ||
} from './api/Transaction'; | ||
|
||
// internal exports | ||
export { setSDKVersion as _setSDKVersion } from './core/version'; | ||
export { | ||
ReferenceImpl as _ReferenceImpl, | ||
QueryImpl as _QueryImpl | ||
} from './api/Reference_impl'; | ||
export { repoManagerDatabaseFromApp as _repoManagerDatabaseFromApp } from './api/Database'; | ||
export { | ||
validatePathString as _validatePathString, | ||
validateWritablePath as _validateWritablePath | ||
} from './core/util/validation'; | ||
export { UserCallback as _UserCallback } from './core/view/EventRegistration'; | ||
export { QueryParams as _QueryParams } from './core/view/QueryParams'; | ||
|
||
/* eslint-disable camelcase */ | ||
export { | ||
hijackHash as _TEST_ACCESS_hijackHash, | ||
forceRestClient as _TEST_ACCESS_forceRestClient | ||
} from './api/test_access'; | ||
/* eslint-enable camelcase */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,88 +1,25 @@ | ||
/** | ||
* @license | ||
* Copyright 2021 Google LLC | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
import { Client } from 'faye-websocket'; | ||
|
||
import { setWebSocketImpl } from './realtime/WebSocketConnection'; | ||
|
||
setWebSocketImpl(Client); | ||
|
||
// Identical to the exports from api.ts, but doesn't include getDatabase() | ||
// to avoid dependency on @firebase/app. | ||
// This entry point should only be consumed by Admin SDK | ||
export { | ||
Database, | ||
EmulatorMockTokenOptions, | ||
enableLogging, | ||
goOffline, | ||
goOnline, | ||
connectDatabaseEmulator | ||
} from './api/Database'; | ||
export { | ||
Query, | ||
DatabaseReference, | ||
ListenOptions, | ||
Unsubscribe, | ||
ThenableReference | ||
} from './api/Reference'; | ||
export { OnDisconnect } from './api/OnDisconnect'; | ||
export { | ||
DataSnapshot, | ||
EventType, | ||
QueryConstraint, | ||
QueryConstraintType, | ||
endAt, | ||
endBefore, | ||
equalTo, | ||
get, | ||
limitToFirst, | ||
limitToLast, | ||
off, | ||
onChildAdded, | ||
onChildChanged, | ||
onChildMoved, | ||
onChildRemoved, | ||
onDisconnect, | ||
onValue, | ||
orderByChild, | ||
orderByKey, | ||
orderByPriority, | ||
orderByValue, | ||
push, | ||
query, | ||
ref, | ||
refFromURL, | ||
remove, | ||
set, | ||
setPriority, | ||
setWithPriority, | ||
startAfter, | ||
startAt, | ||
update, | ||
child | ||
} from './api/Reference_impl'; | ||
export { increment, serverTimestamp } from './api/ServerValue'; | ||
export { | ||
runTransaction, | ||
TransactionOptions, | ||
TransactionResult | ||
} from './api/Transaction'; | ||
|
||
// internal exports | ||
export { setSDKVersion as _setSDKVersion } from './core/version'; | ||
export { | ||
ReferenceImpl as _ReferenceImpl, | ||
QueryImpl as _QueryImpl | ||
} from './api/Reference_impl'; | ||
export { repoManagerDatabaseFromApp as _repoManagerDatabaseFromApp } from './api/Database'; | ||
export { | ||
validatePathString as _validatePathString, | ||
validateWritablePath as _validateWritablePath | ||
} from './core/util/validation'; | ||
export { UserCallback as _UserCallback } from './core/view/EventRegistration'; | ||
export { QueryParams as _QueryParams } from './core/view/QueryParams'; | ||
|
||
/* eslint-disable camelcase */ | ||
export { | ||
hijackHash as _TEST_ACCESS_hijackHash, | ||
forceRestClient as _TEST_ACCESS_forceRestClient | ||
} from './api/test_access'; | ||
/* eslint-enable camelcase */ | ||
|
||
export * from './api.standalone'; |