Skip to main content
Module

x/rambda/source/splitAt-spec.ts

Faster and smaller alternative to Ramda
Go to Latest
File
import {splitAt} from 'ramda'
const index = 1const str = 'foo'const list = [1, 2, 3]
describe('R.splitAt with array', () => { it('happy', () => { const result = splitAt(index, list)
result // $ExpectType [number[], number[]] }) it('curried', () => { const result = splitAt(index)(list)
result // $ExpectType [number[], number[]] })})
describe('R.splitAt with string', () => { it('happy', () => { const result = splitAt(index, str)
result // $ExpectType [string, string] }) it('curried', () => { const result = splitAt(index)(str)
result // $ExpectType [string, string] })})