projectPath method

String projectPath(
  1. String relativePath
)

Build a path within the project Example: projectPath('app/models/user.dart') -> 'lib/app/models/user.dart'

Implementation

String projectPath(String relativePath) {
  if (relativePath.startsWith('lib/')) {
    return relativePath;
  }
  return 'lib/$relativePath';
}