<template>
  <NFlex justify='center'>
    <NCard>
      <hCode :code='code' language='JavaScript' />
    </NCard>
  </NFlex>
</template>
<script setup>
const code = `function padEnd(string, length, chars) {
  const strLength = length ? stringSize(string) : 0
  return (length && strLength < length)? (string + createPadding(length - strLength, chars)): (string || '')
}`;
</script>