-
Notifications
You must be signed in to change notification settings - Fork 0
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
6 changed files
with
62 additions
and
54 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,10 @@ | ||
{ | ||
"name": "@sinkr/core", | ||
"license": "MIT", | ||
"version": "0.3.9", | ||
"version": "0.3.10", | ||
"exports": { | ||
".": "./src/index.ts" | ||
".": "./src/index.ts", | ||
"./client": "./src/index.browser.ts", | ||
"./server": "./src/index.server.ts" | ||
} | ||
} |
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 |
---|---|---|
@@ -0,0 +1,2 @@ | ||
export * from "./browser"; | ||
export * from "./types"; |
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,2 @@ | ||
export * from "./server"; | ||
export * from "./types"; |
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,52 +1,3 @@ | ||
/** | ||
* Event map for customizing which events can be sent or received. | ||
* | ||
* Override this with module augmentation to specify your own types. | ||
*/ | ||
// eslint-disable-next-line @typescript-eslint/no-empty-object-type | ||
export interface EventMap {} | ||
|
||
/** | ||
* User information for presence channels. | ||
* | ||
* Override this with module augmentation to specify your own types. | ||
*/ | ||
// eslint-disable-next-line @typescript-eslint/no-empty-object-type | ||
export interface UserInfo {} | ||
|
||
/** | ||
* Built-in event for initializing a connection. | ||
*/ | ||
export const initEventSymbol: unique symbol = Symbol("sinkr-init"); | ||
/** | ||
* Built-in event for updating a channel's connected member count. | ||
*/ | ||
export const countEventSymbol: unique symbol = Symbol("sinkr-count"); | ||
/** | ||
* Built-in event for a client connecting to a channel. | ||
*/ | ||
export const joinEventSymbol: unique symbol = Symbol("sinkr-join"); | ||
/** | ||
* Built-in event for a client disconnecting from a channel. | ||
*/ | ||
export const leaveEventSymbol: unique symbol = Symbol("sinkr-leave"); | ||
/** | ||
* Built-in event for a client to be informed of another client joining a presence channel. | ||
*/ | ||
export const memberJoinEventSymbol: unique symbol = Symbol("sinkr-member-join"); | ||
/** | ||
* Built-in event for a client to be informed of another client leaving a presence channel. | ||
*/ | ||
export const memberLeaveEventSymbol: unique symbol = | ||
Symbol("sinkr-member-leave"); | ||
/** | ||
* Built-in event for when the client connects to Sinkr. | ||
*/ | ||
export const connectSymbol: unique symbol = Symbol("sinkr-connect"); | ||
/** | ||
* Built-in event for when the client disconnects from Sinkr. | ||
*/ | ||
export const disconnectSymbol: unique symbol = Symbol("sinkr-disconnect"); | ||
|
||
export * from "./browser"; | ||
export * from "./server"; | ||
export * from "./types"; |
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,49 @@ | ||
/** | ||
* Event map for customizing which events can be sent or received. | ||
* | ||
* Override this with module augmentation to specify your own types. | ||
*/ | ||
// eslint-disable-next-line @typescript-eslint/no-empty-object-type | ||
export interface EventMap {} | ||
|
||
/** | ||
* User information for presence channels. | ||
* | ||
* Override this with module augmentation to specify your own types. | ||
*/ | ||
// eslint-disable-next-line @typescript-eslint/no-empty-object-type | ||
export interface UserInfo {} | ||
|
||
/** | ||
* Built-in event for initializing a connection. | ||
*/ | ||
export const initEventSymbol: unique symbol = Symbol("sinkr-init"); | ||
/** | ||
* Built-in event for updating a channel's connected member count. | ||
*/ | ||
export const countEventSymbol: unique symbol = Symbol("sinkr-count"); | ||
/** | ||
* Built-in event for a client connecting to a channel. | ||
*/ | ||
export const joinEventSymbol: unique symbol = Symbol("sinkr-join"); | ||
/** | ||
* Built-in event for a client disconnecting from a channel. | ||
*/ | ||
export const leaveEventSymbol: unique symbol = Symbol("sinkr-leave"); | ||
/** | ||
* Built-in event for a client to be informed of another client joining a presence channel. | ||
*/ | ||
export const memberJoinEventSymbol: unique symbol = Symbol("sinkr-member-join"); | ||
/** | ||
* Built-in event for a client to be informed of another client leaving a presence channel. | ||
*/ | ||
export const memberLeaveEventSymbol: unique symbol = | ||
Symbol("sinkr-member-leave"); | ||
/** | ||
* Built-in event for when the client connects to Sinkr. | ||
*/ | ||
export const connectSymbol: unique symbol = Symbol("sinkr-connect"); | ||
/** | ||
* Built-in event for when the client disconnects from Sinkr. | ||
*/ | ||
export const disconnectSymbol: unique symbol = Symbol("sinkr-disconnect"); |