How to add a custom font?

That mixin was very useful for importing font files. I have slightly improved it for my use case (I was using it inside an ember addon).

$font-url: '/<app/addon name>/fonts';

@mixin font-face($name) {
    @font-face {
        font-family: $name;
        src: url("#{$font-url}/#{$name}.woff2") format("woff2"),
            url("#{$font-url}/#{$name}.woff") format("woff");
    }
}

@include font-face('font--name-400');
body {
    font-family: 'font--name-400';
}