mirror of
				https://codeberg.org/yeentown/barkey.git
				synced 2025-10-30 21:14:12 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			14 lines
		
	
	
	
		
			439 B
		
	
	
	
		
			TypeScript
		
	
	
	
	
	
			
		
		
	
	
			14 lines
		
	
	
	
		
			439 B
		
	
	
	
		
			TypeScript
		
	
	
	
	
	
| /*
 | |
|  * SPDX-FileCopyrightText: syuilo and misskey-project
 | |
|  * SPDX-License-Identifier: AGPL-3.0-only
 | |
|  */
 | |
| 
 | |
| const canvas = globalThis.OffscreenCanvas && new OffscreenCanvas(1, 1);
 | |
| // 環境によってはOffscreenCanvasが存在しないため
 | |
| // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
 | |
| const gl = canvas?.getContext('webgl2');
 | |
| if (gl) {
 | |
| 	postMessage({ result: true });
 | |
| } else {
 | |
| 	postMessage({ result: false });
 | |
| }
 |