Alternative for .inc files
Actually there seems to be nothing wrong about using *.inc files in D8. Have a look at the Update core module. Quite some *.inc files present: cgit.drupalcode.org.



Nevertheless I tend to follow Symfony's best practice examples when it comes to stuff like that.

[Symfony Docs] Organizing Your Business Logic

[Stack Overflow] Where to put model helper functions in Symfony2

Means you'll add a new class under src/Utils. For example:

src/Utils/HelperFunctions.php
src/Utils/FooBar.php


And then wherever you need it, you reference it:

use Drupal\MYMODULE\Utils\HelperFunction;
use Drupal\MYMODULE\Utils\FooBar;


And then you'd call a certain function like so:

$site_color = HelperFunctions::getSiteColor();
$foo_bar    = FooBar::returnFooBar();




And when I'm still unsure, I'll search inside the core and contrib modules how they did it.