Tauri Core API - v2.6.0
    Preparing search index...

    Function extname

    • Returns the extension of the path.

      Parameters

      • path: string

      Returns Promise<string>

      import { extname } from '@tauri-apps/api/path';
      const ext = await extname('/path/to/file.html');
      assert(ext === 'html');

      1.0.0