node_modules.apollo-codegen-scala.src.values.ts Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of apollo-client-maven-plugin Show documentation
Show all versions of apollo-client-maven-plugin Show documentation
Maven plugin for generating graphql clients
import { LegacyCompilerContext } from 'apollo-codegen-core/lib/compiler/legacyIR';
import CodeGenerator from 'apollo-codegen-core/lib/utilities/CodeGenerator';
export function escapedString(string: string) {
return string.replace(/"/g, '\\"');
}
export function multilineString(generator: CodeGenerator, string: string) {
const lines = string.split('\n');
lines.forEach((line, index) => {
const isLastLine = index != lines.length - 1;
generator.printOnNewline(`"${escapedString(line)}"` + (isLastLine ? ' +' : ''));
});
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy