Skip to content

Commit

Permalink
feat: add web definition
Browse files Browse the repository at this point in the history
  • Loading branch information
riderx committed Oct 24, 2021
1 parent c3cf859 commit 7f70a1c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/definitions.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
export interface CapacitorUpdaterPlugin {
echo(options: { value: string }): Promise<{ value: string }>;
updateApp(options: { url: string }): Promise<{ done: boolean }>;
}
6 changes: 3 additions & 3 deletions src/web.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import type { CapacitorUpdaterPlugin } from './definitions';
export class CapacitorUpdaterWeb
extends WebPlugin
implements CapacitorUpdaterPlugin {
async echo(options: { value: string }): Promise<{ value: string }> {
console.log('ECHO', options);
return options;
async updateApp(options: { url: string }): Promise<{ done: boolean }> {
console.log('Cannot updateApp in web', options);
return { done: false};
}
}

0 comments on commit 7f70a1c

Please sign in to comment.