File tree Expand file tree Collapse file tree 1 file changed +0
-27
lines changed
packages/svelte/src/compiler Expand file tree Collapse file tree 1 file changed +0
-27
lines changed Original file line number Diff line number Diff line change @@ -241,19 +241,6 @@ function validator(fallback, fn) {
241241 } ;
242242}
243243
244- /**
245- * @param {number } fallback
246- * @returns {Validator }
247- */
248- function number ( fallback ) {
249- return validator ( fallback , ( input , keypath ) => {
250- if ( typeof input !== 'number' ) {
251- throw_error ( `${ keypath } should be a number, if specified` ) ;
252- }
253- return input ;
254- } ) ;
255- }
256-
257244/**
258245 * @param {string | undefined } fallback
259246 * @param {boolean } allow_empty
@@ -273,20 +260,6 @@ function string(fallback, allow_empty = true) {
273260 } ) ;
274261}
275262
276- /**
277- * @param {string[] } fallback
278- * @returns {Validator }
279- */
280- function string_array ( fallback ) {
281- return validator ( fallback , ( input , keypath ) => {
282- if ( input && ! Array . isArray ( input ) ) {
283- throw_error ( `${ keypath } should be a string array, if specified` ) ;
284- }
285-
286- return input ;
287- } ) ;
288- }
289-
290263/**
291264 * @param {boolean | undefined } fallback
292265 * @returns {Validator }
You can’t perform that action at this time.
0 commit comments