feat: remove obsolete packages [fixes DXJ-462] (#337)

* Remove api package

* Not publish interface package

* Refactoring of interface package

* Fix aqua imports

* Change impl of isFluencePeer

* Remove unused property
This commit is contained in:
Akim
2023-09-05 21:38:59 +07:00
committed by GitHub
parent 18a972b573
commit e7e617661f
18 changed files with 597 additions and 1343 deletions

View File

@ -146,24 +146,6 @@ export interface IFluenceClient extends IFluenceInternalApi {
getRelayPeerId(): string;
}
/**
* For internal use. Checks if the object is a Fluence Peer
*/
export const asFluencePeer = (fluencePeerCandidate: unknown): IFluenceClient => {
if (isFluencePeer(fluencePeerCandidate)) {
return fluencePeerCandidate;
}
throw new Error(`Argument ${fluencePeerCandidate} is not a Fluence Peer`);
};
/**
* For internal use. Checks if the object is a Fluence Peer
*/
export const isFluencePeer = (fluencePeerCandidate: unknown): fluencePeerCandidate is IFluenceClient => {
if (fluencePeerCandidate && (fluencePeerCandidate as any).__isFluenceAwesome) {
return true;
}
return false;
};