UNPKG

@lucide/svelte

Version:

A Lucide icon library package for Svelte applications.

22 lines (21 loc) 552 B
/** * @file * @license @lucide/svelte v1.17.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */ /** * Check if a component has an accessibility prop * * @param {object} props * @returns {boolean} Whether the component has an accessibility prop */ export const hasA11yProp = (props) => { for (const prop in props) { if (prop.startsWith('aria-') || prop === 'role' || prop === 'title') { return true; } } return false; };