0cb863765a5b9419b83eae77201a7494d6bce6a7dff0943918778d0d14b8a751a9ec24d2068319216a14cec1d1a1b01a668857d3a15c628461037df159efe2 863 B

12345678910111213141516171819202122
  1. import {Value} from './index';
  2. /**
  3. * Sass's [function type](https://sass-lang.com/documentation/values/functions).
  4. *
  5. * **Heads up!** Although first-class Sass functions can be processed by custom
  6. * functions, there's no way to invoke them outside of a Sass stylesheet.
  7. *
  8. * @category Custom Function
  9. */
  10. export class SassFunction extends Value {
  11. /**
  12. * Creates a new first-class function that can be invoked using
  13. * [`meta.call()`](https://sass-lang.com/documentation/modules/meta#call).
  14. *
  15. * @param signature - The function signature, like you'd write for the
  16. * [`@function rule`](https://sass-lang.com/documentation/at-rules/function).
  17. * @param callback - The callback that's invoked when this function is called,
  18. * just like for a {@link CustomFunction}.
  19. */
  20. constructor(signature: string, callback: (args: Value[]) => Value);
  21. }