mirror of
https://github.com/ianstormtaylor/slate.git
synced 2025-08-25 16:20:49 +02:00
Add Javascript Examples Support (#5722)
* chore: moved all ts files for examples to examples/ts * add: tsc to eject js and jsx output * example: add js transpiled examples * example: update example site to show both js and ts code * chore: fix yarn lint * fix(example): getAllExamplesPath
This commit is contained in:
5
site/examples/ts/utils/environment.ts
Normal file
5
site/examples/ts/utils/environment.ts
Normal file
@@ -0,0 +1,5 @@
|
||||
export const IS_MAC =
|
||||
typeof navigator !== 'undefined' && /Mac OS X/.test(navigator.userAgent)
|
||||
|
||||
export const IS_ANDROID =
|
||||
typeof navigator !== 'undefined' && /Android/.test(navigator.userAgent)
|
Reference in New Issue
Block a user