Skip to content

Commit

Permalink
Update wellknowntypes to support strict ESM (#20)
Browse files Browse the repository at this point in the history
  • Loading branch information
tatethurston authored Oct 6, 2022
1 parent 0eedb43 commit d69843e
Show file tree
Hide file tree
Showing 8 changed files with 31 additions and 17 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## v0.0.13

Update package [Protocol Buffers Well-Known Types](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf) to enable strict ESM.

## v0.0.12

[Protocol Buffers Well-Known Types](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf) are now exported from `protoscript`. References to well-known types are now imported from `protoscript` rather than being generated. This is a non breaking change. If you have well-known types in your project, you can remove the `google/protobuf` directory that was generated in previous versions alongside your other `.pb.js/ts` files.
Expand Down
14 changes: 7 additions & 7 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"jest": "^29.0.1",
"prettier": "^2.7.1",
"prettier-package-json": "^2.6.4",
"protoscript": "*",
"protoscript": "^0.0.12",
"typescript": "^4.7.4"
}
}
2 changes: 1 addition & 1 deletion public.package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "protoscript",
"version": "0.0.12",
"version": "0.0.13",
"description": "A Protobuf runtime and code generation tool for JavaScript and TypeScript",
"license": "MIT",
"author": "Tate <[email protected]>",
Expand Down
10 changes: 8 additions & 2 deletions src/runtime/well-known-types/api.pb.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,14 @@
import type { ByteSource } from "protoscript";
import { BinaryReader, BinaryWriter } from "protoscript";

import { Option, OptionJSON, Syntax, SyntaxJSON } from "./type.pb";
import { SourceContext, SourceContextJSON } from "./source_context.pb";
import {
Option,
OptionJSON,
SourceContext,
SourceContextJSON,
Syntax,
SyntaxJSON,
} from "protoscript";

//========================================//
// Types //
Expand Down
3 changes: 1 addition & 2 deletions src/runtime/well-known-types/type.pb.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@
import type { ByteSource } from "protoscript";
import { BinaryReader, BinaryWriter } from "protoscript";

import { SourceContext, SourceContextJSON } from "./source_context.pb";
import { Any, AnyJSON } from "./any.pb";
import { SourceContext, SourceContextJSON, Any, AnyJSON } from "protoscript";

//========================================//
// Types //
Expand Down
10 changes: 8 additions & 2 deletions well-known-types/google/protobuf/api.pb.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,14 @@
import type { ByteSource } from "protoscript";
import { BinaryReader, BinaryWriter } from "protoscript";

import { Option, OptionJSON, Syntax, SyntaxJSON } from "./type.pb";
import { SourceContext, SourceContextJSON } from "./source_context.pb";
import {
Option,
OptionJSON,
SourceContext,
SourceContextJSON,
Syntax,
SyntaxJSON,
} from "protoscript";

//========================================//
// Types //
Expand Down
3 changes: 1 addition & 2 deletions well-known-types/google/protobuf/type.pb.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@
import type { ByteSource } from "protoscript";
import { BinaryReader, BinaryWriter } from "protoscript";

import { SourceContext, SourceContextJSON } from "./source_context.pb";
import { Any, AnyJSON } from "./any.pb";
import { SourceContext, SourceContextJSON, Any, AnyJSON } from "protoscript";

//========================================//
// Types //
Expand Down

0 comments on commit d69843e

Please sign in to comment.